Home Assistant Add-On: X10 (CM11) to MQTT Gateway

I am using some 20+ year-old Leviton X10 4-button 6400 wall controllers as triggers in Home Assistant. The MQTT trigger is available for automations and scenes.

Not using the unique_id field in my yaml. Wondering if not using lower-case might your issue.

1 Like

I’ve read the entire thread and haven’t seen anyone else run into this problem.

My current setup is this add-on running on supervised HassIO running on VMware ESXi 6.7. Heyu is having trouble communicating with the serial port, a real serial port on /dev/ttyS0. I also tried a USB to serial adapter and got essentially the same results.

My troubleshooting so far:

  1. docker exec into the add-on container. Run heyu info multiple times. It responds once in a while but mostly times out.
  2. docker run a vanilla alpine container on a different docker host. Use --device=/dev/ttyS0 to pass in the serial port. Build heyu using the same sequence this container uses. Heyu works reliably.
  3. docker run a vanilla alpine container by ssh’ing into HA. Build heyu as in step 2. Heyu is mostly unresponsive just like in step 1.

Is anyone here wiser in the ways of HassOS who might know what might be getting in the way?

After a week or so of trying everything I could think of I finally gave up and reworked this plugin to run in a plain-old docker environment with no Home Assistant dependencies. For whatever reason, it works fine for me.
If anyone else needs it, it’s here: GitHub - dbrand666/docker-heyu-mqtt: A dockerized heyu to mqtt interface inspired by mmotley999's HassOS add-on

One of the last requests in this thread was related to actually getting the switches to show up as devices in Home Assistant. I’ve done the configuration.yaml file entry for one device. Can’t get it to show up as a device anywhere in Home Assistant. Similar situation to PAOK1926’s post above. Is there a final step to do to get devices to show up? I can post additional details or screenshots if someone is able to assist with this.

HA has changed the mqtt configuration format. This is how it’s done now.

1 Like

Thank you yeeCdn!! Changing my one test light to your format in the configuration.yaml file actually got my one light to show up in the Overview section of Home Assistant. So I can visually see a light there now. However, it doesn’t turn on yet. I’ve noticed my Add-on is stopping itself.

I can press Start of course and it seems to start, but if I go back to that tab a minute later it is back to the state shown above (not started).

The log looks like this:

My super basic (for now) configuration.yaml looks like this:

Any suggestions as to what might be happening? Note the CM11a is tested and working under other platforms, just not Home Assistant currently.

The addon has worked flawlessly for me since 2021 thro all the HA updates. I’m now on HA 2024.3.2.
Can only guess what’s causing you problem. The last 2 lines in your log seems to indicate its not getting mqtt services. Does mqtt works with other devices?
Go thro previous post to setup mqtt server. Check HA change log re mqtt server setup for any changes.
Note my system is running on a Pi, not docker.

I’m brand new to Home Assistant. Mine is running on a Windows box in Oracle VirtualBox using HAOS, having followed a guide showing how to set this up. I would answer your question by saying that MQTT does seem to be working because I do have another Add-on called OmniLink Bridge running which is an MQTT bridge that is allowing my old security/alarm system to show up in Home Assistant. That is working, so I take that to mean MQTT is working, yes? Again, most of this jargon is foreign to me; I’m learning as I go here.

I don’t have knowledge re running HA in virtual environment. Previous posts in this thread may help.
The last to lines in your log may indicated your CM11 could not get through to your windows physical serial/usb ports. Perhaps check other threads on how to get to the physical serial/usb ports from virtualbox.
Sorry I don’t have the knowledge to help you further.

1 Like

@yeeCdn THANK YOU so much!
Your suggestions and your screenshots have led me to some success tonight. I managed to get two of my X10 devices controlled through Home Assistant. I had to get my Oracle VirtualBox session to enable a COM port. That wasn’t as straight forward as it sounds as I had to try some different combinations of Local port and Virtual port, but eventually found this to work for my setup:
image
Some combinations on this screen were actually enough to cause Home Assistant to not boot at all. Anyways, this combination finally worked, and once I changed the Add-on to use COM3 (/dev/ttyS2) things seemed to work. The screenshot of your configuration.yaml file was invaluable for me. Thank you again. No dimming for my dim-able X10 protocol lights with this setup, but it’s better than nothing.

Now I’ll go about populating my configuration.yaml file fully, and then I’ll move on to figuring out how to do HA Dashboards. :slight_smile:

I just came to say: keep up the good work!

So thrilled to see people still using X10. I actually had a whole house wired up with X10 everything (lights, dimmers, appliances, curtains, even self made custom Android wall panels with Homeseer). I still have all the hardware but obviously can’t really find a use case for it now that zigbee/wifi devices are so common and cheap. Somebody give me a use-case for X10? I would set it all up again for any excuse :slight_smile:

1 Like

I don’t know about a present day use-case as to why you would pick X10 over any of the more modern choices, but for me, I’ve got a 20 year old installation of two dozen X10 protocol “PCS SmartSwitches” in place of all my standard wall light swithces. They were very expensive to install at the time and I’m trying to avoid the cost of replacing them all. I want to integrate them with Home Assistant as I potentially move away from HomeSeer. My X10 devices work very well because I have a device on my electrical panel that couples the two electrical phases of the power in my house, allowing X10 signals to travel as reliably as one could hope for. Other than the low cost of some X10 hardware, I don’t see much reason to add X10 into one’s system today; I think X10’s use today is more likely just by people like me that are trying to salvage/maintain an older existing setup. But that’s just my 2 cents. For all I know there could be people out there that just love the challenge of using older technology for as long as possible and to those people I say power to you! :slight_smile:

Good job solving the problem! And glad to see you post the solution so others can benefit.

1 Like

Use case ditto michae1a1ee. Zigbee/wifi devices are cheap but not $0.00 for the X10 devices you already had. If they had work well in your house wiring b4, why not?

Another use case : with just a CM11, Tm751 and this addon, the HR12 palmpad becomes a rf to mqtt remote. My X10 HR12 controls non-X10 devices like Gosund wall switchs, non-smart Phillips tv, 7ch Onkyo receiver, and esphome/tasmota devices.