[Solved] Add location to location, how?

openHABian 3.2.0

Starting with OH3.
Following the tutorial Semantic Model | openHAB
It has this picture:

I want to add Indoors to Argyle Court, but do not have the add location menu shown above.

What am I missing?

Looks like they are of type “group” not “location” – groups seem hierarchical … (i am confused too - also novice) - only the semantic type is location - just tried works fine

1 Like

Yes, a location is simply a group with the “location” semantic tag.

1 Like

To expand on Gaël’s answer, a location is just a Group that has a location tag applied. So to make a location part of a parent location, you simply make it a member of that parent Group.

A Deep Dive into the Semantic Model might be worth a review. I’ve not figured out the best place/way to add it to the official docs but I plan on doing that at some point.

@Max_G, looking more closely at your screen shot I think I see the problem. A semantic location is and can only be an Item of type Group. But you’ve created ArgyleCourt as an Item of type Location (i.e. a lat/lon coordinate). In order to be a location in the semantic model, that Item must be a Group.

It’s an unfortunate overloading of the term “Location”.

  • Semantic Location: Group Item with one of the location semantic tags applied
  • Item of type Location: An Item whose state consists of a latitude and longitude coordinate
1 Like

Your replies are gold… and in most cases I get it; like in this case. :slight_smile:
For the life of me I struggle with OH3 big time.
If it weren’t’ for trailing ZigBee (which I do not have in OH2) I would not make the move.
However, I get it, that I have to adopt OH3 eventually.

I don’t see the big picture yet… how the bits fit together.
It seems I am literally starting from scratch… (coming from exclusively text-based config)

No need to reply… this is just a sigh of frustration. :slight_smile:

So in response to what I am trying here…
I have created an item which is of type group (sounds familiar) and gave it the semantic class Location.
All subsequent location groups will be created the same way, in addition to assigning to a parent group.

Now that I have done this, it seems straight forward… maybe it is familiarisation more than anything else…

Now looking forward to days of creating items and things and stuff…

Would it be faster to create some sort of text file I can bulk import rather than doing this all in the UI?
[edit 1] found “add items from textural definition” in developer tools.
Also like the Developer sidebar!

Thank you all.

Basically, you can use OH3 as you would have done with OH2. Stay on file based configuration, don’t use MainUI but only sitemaps. Concepts are unchanged.

I recommend all users to review the Getting Started Tutorial. I strongly urge any user who is coming from an older version of OH to review the Getting Started Tutorial if they want to use MainUI to manage OH. If you want to use text configs and sitemaps, you can continue on as you always have.

That big picture you are missing should become more clear after reading through those. While the tutorial does not refer back to those older versions of OH, the concepts should be familiar to anyone who has used OH 2 at least and each page builds on the previous one.

If you plan on using the semantic model (which is not required) I would instead create/discover the Things and then use “create equipment from Thing” or “create points from Thing” instead. It’s really quite a pain to set up the semantic model in text configs and even more of a pain to retrofit a bunch of Items into the model after they exist. When you create the Items from the Thing though, it gets situated into the model right off the bat. And you get a chance to create lots of Items in one go.

I found this approach to be the most efficient way to get your Items into OH.-