Raspberry pi Heating Boiler Control System Relay: Control gas boiler from raspberry pi gpio with relay by connecting it to room thermostat connection on gas boiler without passing any voltage to gas boiler or at least this is how i did it as my gas boiler had thermostat connector available, you need to check this with your boiler user/technical manual.
You can control high voltage electronic devices using relays modules that are readily available in the market. I am using the Sainsmart 2 channel 5v relay module, which has 2 relays. The high voltage side output connector has 3 pins, the middle one is the common pin. One of the two pins is normally open connection and the other one for normally closed connection and can be activated by by raspberry pi. The reason i m using two channel relay as i can not find any single channel relay with optocoupler ic.
“DO NOT MAKE ANY CHANGES TO YOUR HEATING SYSTEM UNTIL UNLESS YOU KNOW WHAT YOU ARE DOING, contents provided here are for information and education purpose only, I take no responsibility for any loss or damage to you or your property.”
All wiring and connection from raspberry pi gpio to relay board and voltage connection to relay board. on same note make sure you follow wiringpi gpio pin number as below table.
You need to make sure to have WiringPi installed as well on your raspberry pi and have correct WiringPi gpio pins configured for each zone and for gas boiler in boiler mysql/mariadb table. For troubleshooting i have done one php script to do some testing zone and boiler relay.