Best solutions for a wired house with buttons/lights/climate

Hello everybody!

I know this subject circled around the forum time to time, but I could not find any comprehensive post/tutorial on that.

I understand HA was created for DYI solutions which means most of users would use wifi based communication to control their smart home configuration. I had this possibility to wire my reconstructed house completely with CAT8 ethernet cable, because my goal from the beginning was to avoid wireless technology as much as possible. The are many reasons, one of them is the fact, that the house is in the middle of city with literally 50+ wifi networks available on the location. I just have too many bad experiences with the wifi reliability. Of course I accept single wireless solutions as an addon.

The house has 3 floors, will have around 40 light points and 40 light switches, around 30 switchable AC outlets, 12 heating zones, some with radiators only, some with both radiators and floor heating, some with floor heating only (heating is gas boiler btw). All electricity is configured in star configuration (all cables to each electrical outlet, no matter light or outlet go independently from the technical room).

Heating will be controlled on manifolds with electric valves which, as the lights and outlets, would be powered via typical “aliexpress” relays. This is the easy part i think.

Another story is the sensor part. All the light switches will be “doorbell type”, connected via ethernet cables (there is no typical AC cable for the switch locations) to the technical room. In some locations, together with the light switches I want to put temperature/humidity sensors (just loosely hanging in the switch “hole” behind the switch itself) also connected to the ethernet cable.

I also have to integrate bunch of 1-wire sensors in the heating room, which provide info about the temperature of certain elements of the system.

The big question is how to connect the sensor part to the RPi. At the beginning I thought i can just put them all to RPi directly. Theoretically, putting most of the sensors on 1-Wire should do the job. But what about the light switches? There are just a simply button entity. I experimented using them with I2C and found, what is obvious for more experienced people, that it cannot be regarded reliable on distances bigger than 1 meter. Also, having 40 buttons, I need expanders, another hint found on the Web says expanders don’t work well with button entities, as those should be connected directly to RPi pins.

Then I found that generally people prefer to use Arduinos as a kind of proxy between the RPi and the sensor network using mysensors, as Arduino is much more reliable working with sensors and buttons, and also provide a cheap way to expand number of pins, that can be used for buttons. Arduinos has the another advantage - ability to work independently and do the switches and buttons dependencies itself only updating the state of the whole system to RPi (of course also executing any commands from RPi in that matter) which increases the reliability f.e. when RPi SD card will die.

The wiring and all that hardware is on place, next week I will start my experiments on the site. I assume temperature sensors will cause no problems, as 1-wire is quite reliable and will work on distance with CAT8 cable. But how can I solve the button issue? What is the best way connect them to RPi?

Another question on the Qubino Smart Meter. The only thing a I can found about this device of the forum is that it is faulty and do not work as intended with HA, constantly disconnecting. I do not know if those are just rare situations, and lots of people use it with success (you usually do not start a forum thread to say that something works just right), or maybe the problems are common.

1 Like

In my home, I use ESP8266 boards to handle switches and relays. They send/receive commands via mqtt to my pi4 running ha.

ESP’s are basically arduinos with built in wifi. Makes interfacing easy, but you don’t/can’t use wifi, so that would be a problem. Maybe reconsider the no wifi. I have a couple ESP’s in the backyard, pretty far away away from my router. They disconnect from the mqtt server at times, but always reconnect and work fine.
I run software call espeasy in my esp’s, but I’d recommend trying tasmota or esphome, probably easy to get going.
You could try a different wifi channel, I think people tend to use the default ch and that may be not be the best solution.

But if wifi is a definite no, I’d look at pi zero’s. You could set them up as mqtt clients, then run the mqtt server from HA.
You could also use arduinos, but you’d need to add an ethernet interface, and it would end up costing more than a pi zero after adding ethernet to it.

This is exactly how I am setting my house up as I slowly gut and rebuild every room.

The only difference is that instead of running all lines back to a central location for the house, I run all lines back to a central box for that room.

In that box is an I/O board that communicates via MQTT over wired Ethernet (some with PoE) to Home Assistant. Switches, buttons and other low voltage inputs send control signals, then outputs trigger stuff (mainly relays). The boards also have sensors (DHT22, BME280, RFID, etc. etc.) depending on what else is needed.

No critical / permanent infrastructure on WiFi. Though WiFi used for things like power bars because they move around sometimes. Or for temp stuff.

Now you’re going to ask me where I bought these boards. I didn’t. I couldn’t find anything that met all my requirements (a big one of those that I control the firmware) so I had to design them.

https://community.home-assistant.io/t/arduino-nano-w5500-ethernet-mqtt-based-8-channel-opto-isolated-i-o-board/

https://community.home-assistant.io/t/custom-atmega-1284-board-with-8-opto-isolated-inputs-8-a-d-i-o-spi-i2c-2xuart-w5100-ethernet-and-poe-ota-mqtt/

If you don’t want to go through the whole fabrication thing, then there are Arduinos with built in Ethernet where all you have to do is add the I/O. Superhouse makes high quality, reliable products for this. Yes, you’ll pay more than WiFi. Yes, it will still be running 100 years from now. :slight_smile:

They don’t have any opto-isolated input shields, but Google found a bunch.

1 Like

Don’t. Use bulletproof industrial grade hardware that interfaces with the network, use HA to monitor and override control. You should be able to literally rip the home automation controller out and everything should still mostly function normally. Using hobby grade hardware to manage the entire homes lighting and climate control systems may lead to disaster.

Are those expansion boards reliable? How will they handle things like EMP from nearby lightning? Will they catch fire if they get too hot or if there is a power spike? Will they run reliably for years with minimal maintenance? What happens if you need more power than a pi, do you need to redesign the whole system?

Compartmentalizing also makes interconnection cleaner and replacement easier. The 1-wire controller would be a completely isolated device that connects to the network and does nothing but talk to 1-wire devices. The wall button receiver would be a completely isolated device that connects to the network and does nothing but receive button presses. The button receiver interfaces with the logic controller. The logic controller connects to the relay board that operates high power relays for lighting and outlet control.

Industrial logic controllers like the X600 have a 32-channel 1-wire bus controller on board, and communicate to HA using Modbus/TCP, and can even be used to manage central heating and air conditioning, replacing a central thermostat with a network of temperature sensors for more accurate energy control. They can control hundreds of relays and sensor inputs simultaneously.

What did you end up using for lighting control? I am in the same situation.

Hi,
I am trying to design a commercial project with HA wired and reliable devices. Can i consult you and do the project together ? please mail me. [email protected]

Hello everybody.

Yes, the house is finished, the system is partially working - for now the relay part. I decided to give chance to mysensors - still everything controlled in the control room. I have RJ45 laid everywhere (to physical switches (buttons) and possibly various sensors. For now I made some experiments with RJ45 and arduino and compared to RPi it works like a charm - i think the 5v vs 3.3v is the big gamechanger here. Switch action is recognized by mysensors via RJ45 on distances like 30m (i haven’t checked more). I will be starting connecting real wall switches in the coming weeks and post any problems if I have one. The big issue for me is best way to implement double/long buttons. I can do it in mysensors, but this means i will be not able to reconfigure the effects of double/long buttons via HA, but each time i would have to upload new sketches to arduinos. I will try to solve it practicaly while installing switches.

1 Like

I’m in a similar situation and soon setting up superhouse state monitor hardware for light switches and pir sensors. Superhouse hardware and software is being developed on an ongoing basis in community driven open source way. I want my light switches to work reliably so ok to paying extra for a well thought out product. Sensors temp hum co2 are also all wired in my case but using a separate system. All of the above is integrated into home assistant and node red.

Happy to share approaches

Which temp hum and co2 sensors are your choice? I’m looking for wired one.