X10 Configuration Assistance for openHAB newbie

  • Platform information:
    • OS: Windows 10
    • Java Runtime Environment: 1.8.0-191
    • openHAB version: 2.4
  • Issue of the topic: having trouble figuring out how to configure an X10 switch in openHAB

Can someone please point me to information that spells out precisely how to configure an X10 switch in openHAB using the mochadx10 binding? I must not be understanding how this is done. I have been able to configure the rest of what I have done in openHAB so far fairly quickly: bindings for Philips Hue bridge and devices, SmartThings binding and SmartThings devices, TP-Link Kasa outlet devices, and Google Assistant integration.

However, I am stumped on how to get my X10 devices working. I did a similar configuration with SmartThings that involved installing Mochad and Node Red on a Raspberry Pi, and overall, it was fairly easy. I am stuck in openHAB.

I have created a .things file and a .items file, but nothing appears. Paper UI does not allow adding X10 devices through the GUI, apparently. Any help would be greatly appreciated.

default.things
Thing mochadx10:switch:x10test1 "x10test1"

default.items
Switch x10test1 {mochadx10="a1"}

I can turn the lamp on and off from the mochad server itself. I have configured the IP and port in the openHAB config file for the mochadx10 binding.

So, the Mochad binding is a 1.x binding. This is a very important fact. It means more than just that it is an old binding. It means that there is no support for this binding in PaperUI what-so-ever. There will be no Things. So what you’ve created in your .things file are kind of nonsensical.

You need to define your Items in a .items file and provide the binding configuration string (i.e. something that looks like mochadx10="a2:pl:dim" in the binding config section of your Item.

Dimmer Light_Living_Dimmer "Living Dimmer [%d %%]" (GF_Living) {mochadx10="a2:pl:dim"}

OK, now that you’ve done this, realize that this will not appear as something you can control in PaperUI. Consequently you will need to create a sitemap and put the Items on your sitemap. PaperUI is intended to be an administration UI anyway and you will want to create a sitemap or HABPanel UI for day to day use of your home automation.

Unfortunately OH is undergoing an extended transition from OH 1.x to OH 2.x and while this transition continues there will be cases like these where you simply can’t do it through the UIs yet. Use of OH 1.x version bindings is one of those cases.

See https://www.openhab.org/docs/configuration/sitemaps.html and HABPanel | openHAB (or if you are really adventurous https://www.openhab.org/docs/configuration/ui/habot/) for options to see and control this 1.x bound Item.

There is a lot to figure out here in openHAB. Thanks to your response I can now turn on and off my test lamp from HABPanel. I thought I was going crazy. I knew it had to be something simple, but was lost. I have also been able to figure out my first simple motion detector script that will turn on a light and then turn it off based on a timer. I have another question about why my Hue motion timer keeps getting renamed, along with the associated temp and light sensors. So much to learn. Thanks for your help on this forum!

3 Likes