Same source for Habpanel and BasicUI

Hello

  • Platform information:
    • Hardware: NUC
    • OS: Ubuntu
    • openHAB version: OpenHABian
  • Issue of the topic:

I used the demo installation mode to have some preconfigured items etc. Now I think I’m gonna use the basic-ui-pannel and the habianpanel at the same time.
In my installation I’ve got a demo.items and a firstimtems.items file. Both are in use, one for habpanel and the other for basicui (as far as I can tell).

Question: Is it possible to use just one file with the same item names as source for basicui/habpanel. I guess it is, am I right with that?

Thanks

The number of items files doesn’t matter - openHAB will read all items file and create the Items in the configuration for you. You can then use those items in your .sitemap file (for BasicUI), or in Habpanel (via widgets). So, Habpanel/BasicUI can/will use the same Items in your configuration, regardless of how many .items files you created to define them.

Sorry, I wasn’t clear. I mean the item names for example:

I have for one light two different item names. One item name ia uses in habpanel and one in basicui. But that makes imho no sense. So I’d like to use one file (thanks for the answer :+1:) and the same item name. That should be possible, right?

You only need one single item name (per item) which can be used in any of the UI’s.

  • BasicUI
  • HABPanel
  • ClassicUI

People tend to break up their item files by geography (rooms, floors) equipment (pool, garage doors) etc. OH will read all of the files with the .items extension in the Items folder. The organization is up to you.

Squid

1 Like

Just to be clear regarding what bartus and KidSquid are saying.

You can never have two Items with the same name.

You should only have one Item defined.

You can put that one Item on a sitemap and HABPanel at the same time.

1 Like

Thanks :+1: