Anyone up for a challenge? Nuuubeee here

Hello, all. Think I’m gonna try one more time to get my mind wrapped (hopefully at least a little bit) around configuring OH. Have tried on my own a number of times, and have given up only one less time than I have started – this time. My upfront apologies, but it looks like I’m gonna need a HUGELY patient individual, or group, to hold my hand.

I’ve successfully installed openHABian on an RPi3B+, have mosquitto installed and running, am able to SSH into it. (I have assigned static IPs nor nearly everything on my network). I followed the openHAB tutorial and selected the Standard setup, and have the MQTT and the Network bindings installed via PaperUI. I have Add-on Management | Access Remote Repository, Inbox | Auto Ignore and Item Linking | Simple Mode turned on (seems like those were all directed in the tutorial), and have one Thing discovered and appearing in the Configuration | Things tab – a cell phone. At this point, I don’t yet have any other hardware Things, though lots of Network Devices appear in the Inbox after doing a search. Following the tutorial, I have a very small sitemap with just the cell phone showing.

Since I don’t have any other Things yet, I wanted to continue learning openHAB by reading. I think I get most general concepts, but I’m far from understanding how to implement them, mostly the configuration files. If I understand correctly, it seems that I should use PaperUI only for discovering things, and do the rest of the configuration manually. But then I run into lots of confusing stuff that seems like they may be important, but I just can’t figure their proper implementation: Visual Studio Code, HomeBuilder to name a couple.

That’s as far as I have gotten in the tutorial. So it seems that I’m at a point where I can’t create any rules since I have nothing to act upon. In the meantime, I thought I could add something non-hardware like Yahoo weather, though reading through others’ experiences, it might be way above my abilities at this point. Yes? No? Maybe?

Where do I go next? VS Code? HomeBuilder? Then what?

See what I mean? LOTS of hand-holding here – TIA

First of all, welcome! You’ve already made great progress getting openHAB installed and running to the point you’re at.

To fully appreciate openHAB and use things like sitemaps and rules, you’ll definitely need more items in your configuration. You may have already read this in the tutorials, but from a very high level, these are the building blocks of openHAB:

Things - Hardware (or software) components you want your home automation system to interact with. For example, a Samsung TV or an HVAC thermostat could be a thing, or the Sun could be a thing. Things have predefined channels to access their controls or data (i.e. Samsung TV thing will have a volume channel, or the Sun thing will have a position channel). You can find the things in your HA system via PaperUI, but read on first.

Bindings - These are the addons (plugins) to the base openHAB system, which interface with the things and expose their channels to you (i.e. Samsung binding will find Samsung TVs and provide access to its volume, mute, power, etc. channels, and the Astro binding will provide access to the Sun thing’s position, angle, season, etc… channels. You can use PaperUI to install bindings, but my preference is to use the addons.cfg file in your openhab-conf/services folder.

Items are variables that connect to the channels of your things and are used in the next few blocks (sitemaps, widgets and rules). These should definitely be defined in *.items files within your openhab-conf/items folder. You can start with a single file, but once your system gets larger, you want to split them up (i.e. use different files to store items for LEDs, lights, HVAC, sensors, etc…). Items are generally each tied to a single channel of a thing (e.g. you’ll have a Number item that connects to the volume channel of your Samsung TV thing and store the current volume level)

Sitemaps organize your items into user-friendly UIs (Basic UI or Classic UI), usually on a functional or architectural grouping (e.g. you’ll have a sitemap that breaks your house into floors, and puts all second floor items in a group that shows when you click on the second floor sitemap frame.

Widgets are a special type of UI building block, used by the HABpanel UI (check out my video here and this blog post from @dcabanero to get an intro on Habpanel). I can honestly say if I was starting openHAB now, I’d create all the items I wanted to control first and go set up a Habpanel UI - it’s the quickest way to a working user interface and easier to learn than sitemap syntax.

Rules are the real point of all of the above - they tie everything together and are what makes your home automation system really automated - that is to say, they perform logic and actions/commands on your items based on the items’ values or other triggers. For example, you could set up a rule that fires when the Motion Item (which is tied to the motion channel on your Zwave motion sensor Thing) receives an update to “ON”. The rule could check the state of the isNight item (which is tied to the night channel of your Astro binding’s sun Thing) and send a command to the HallwayLight Item (which is tied to the power channel of the Phillips Hue binding’s hallway light Thing). You can look at my tutorial to see how I tied Google Home, Phillips Hue and other bindings and used rules to set up entire scenes for my items. Rules can get very complex very quickly, but there’s no better community than this forum to post your attempts and get a quick, fully working rule figured out (usually by @rlkoshak who I think is the most experienced rule expert here :wink: ).

Anyway, this is the basic description of the building blocks, and I used bold text to make you familiar with the interactions between each block and get you thinking/talking in those terms.

As a starting openHab’er, I’d recommend you go into PaperUI and check out all of the bindings you have available. Install any you think you might use (you’ll probably want to install the Astro binding in any case), install the additional UIs (like HABpanel), and start playing with the Demo items files, trying to tie them to the channels on the things you find in your setup (i.e. your phone, network devices, etc…). Also, check out the Tutorials & Examples section of the forum, as well as the new website’s Showcase & How-To’s section, to see some of the fully-working examples others have posted.

Also, check out the VSCode forum topic to set up your extension (it’s become the de facto editor for openHAB configuration files, and it definitely helps with the auto-complete and code validation features).

Enjoy and let us know what else you need to get started!


I’d add Persistence to @bartus list. Persistence lets you store values which can survive a restart of OH or the hardware. See the very excellent documentation on Influx/Grafana thread.

Thanks, guys, for the encouragement.

@bob_dickenson: re: persistence - I have read through the topic in the documentation; think I have a general understanding, though far from applying it. Following the online tutorial, I kinda ran out of steam before getting there since I don’t yet have many Things installed and no rules. I have some hardware on order, have not arrived.

@Bartus: Again, I think I have a basic understanding about how Things, Bindings, and Items relate to each other. I had created a very small sitemap to display on BasicUI the little data that I have available, though I do have a related question - are sitemaps used only for Basic UI and Classic UI?

I ask that because I ultimately desire to go the HabPanel path. (I think I came across your video while poking around some time back. That kinda sealed the deal for using openHAB over other choices.) So, do I need to go through the effort to create a sitemap? Is it needed if I only use HabPanel? Are there reasons to do it anyway?

I’ve looked through the provided Widgets, and looked at the widget gallery; I tinkered with setting up a panel and added a couple of them to get a feel for it. Potentially, really cool stuff. And the mind is awash with ideas and dreams of my future panel. . .

As to VSCode, I’m afraid I’m totally lost. I have it installed on a Windows machine, and have also installed the Git it was looking for, I’ve watched the videos on the VSCode site, and don’t have a clue what to do. I had written all my (tiny) files ssh-ing into the Pi and using Nano. But I don’t know where to begin with VSCode. I read through the whole topic where the openHab extension was introduced, along with all the glowing ‘thumbs-up’, but haven’t figured out how to start. If there’s a BEGINNERS beginners tutorial, I have yet to find it.

Still lots of reading & studying going on otherwise. . .


One more thing - Following the early pages of the tutorial, I opted for the ‘Standard’ package as directed. Is there reason to look at the ‘Demo’ package? If so, can it exist side-by-side with the ‘Standard’? How do I do it. Apologies, really nube stuff. Still overwhelmed, I guess.

Sitemaps: If you really think you won’t be using Classic/Basic UIs, you don’t need them - but, given that Habpanel is still a web-based UI (and only now gaining app-based support - in Habpanelviewer on Android, nothing yet for iOS), I still end up using the Basic UI a LOT, for quick control of OH from my phone, and via the iOS openhab app (which connects to for remote control). If you only intend to use Habpanel, I’d say you can skip the sitemap.

VSCode: I understand you’ve installed the VSCode application itself, then gone into the “Extensions” menu, searched for openHAB and installed it, correct? Next, click on the cog in the bottom left, and select “Settings”. In the text box up top, search for “openhab” and it should pop up all related settings. The most important one will be the “”, where you will want to put your Pi hostname in (likely “openhabianpi” if you did the default install). The next thing you want to do is open the folder with your openhab config files. I’m assuming here you’re on Windows, and can access the openhabianpi shared folders (type \openhabianpi\ in your Explorer window - you should see the openhab-share folder, which contains most of the files you want to edit with VSCode) Map that folder as a new drive, so you can easily access it from Explorer next time. Back in VSCode, click on File -> Open Folder, and browse to the mapped folder/openhab-share folder. Select it, and it should open up all of the folders you previously saw in your ssh terminal…That’s really it! I’ve been thinking about making a quick video on this, maybe I’ll do it next week…

Demo package: Absolutely nothing wrong with using the Demo package - in fact, when I started with openhab, that’s what I installed. Seeing all of the defined items, sitemap entries and the demo rules gave me a good start. I commented out all of the demo stuff, but kept it in my files for reference. Whenever I needed a new item type, I’d look up how it was defined in the commented out section. That saved me a lot of grief, searching for information online, and let me get started making up my system, so I definitely recommend it! Install the Demo package (by changing the setting in your addons.cfg file) and start commenting out everything you don’t need.

Anyway - keep us posted on how you progress. If there’s topics you think are worthwhile having a dedicated video for a beginner to watch, let me know and I’ll put it in my todo list.

Good luck!

Thanks so much, think I both have it set up and understand a little what it’s all about.

@bartus: " Install the Demo package (by changing the setting in your addons.cfg file)". Really dumb question, but where do I find the “addons.cfg” file. Been hunting through directories, have yet to find it. . .

Also, guess I will do sitemaps after all, based on your observation.

Thanks again!

In your /etc/openhab2/services folder.

Thanks. Didn’t drill deep enough and din’t look in the services folder.

The easiest and quickest way to get persistence up and running so you can restore after a restart is using mapdb just a simple text file I still use mapdb for restore on startup and use rrd4j for graphs I plan on moving to influx soon

I would love more videos on how too get stuff working on OH