Controlling the central heating system


In April 2009 I became the proud owner of a new Remeha Avanta central heating unit along with a Honeywell Chronotherm modulation thermostat. My previous thermostat was a RCS TR40 which was hooked up to my home automation system via a serial interface. That setup allowed me to intelligently change the temperature setting, set the clock on the thermostat, and display the outside temperature. It was even possible to display reminders on the thermostat. I knew that last feature would not be possible with the new thermostat, but it would be really nice if I wouldn't lose all of the convenient possibilities I had grown used to.

Automation options

Of course I could still choose to use the old thermostat with the new central heating unit. But using a simple on/off control device would greatly reduce the efficiency of the system compared to a modulating thermostat. Another issue was that the old thermostat was powered from the boiler and the Remeha Avanta doesn't provide a 24V AC connection. Finally, I had the impression that the heating algorithm used in the TR40 wasn't very sophisticated, causing quite big temperature swings around the specified setpoint.

The Honeywell thermostat does provide a so-called "tele" contact that allows a home automation system to override the normal program, forcing the thermostat to a pre-configured temperature setting. But that is a far cry from all the features I used to have available. Then I found that the boiler has a serial interface. There wasn't much information about that available, but Remeha does provide a program that can be downloaded for free. The serial connector only has four connections, so that could be figured out pretty quickly. But after hooking up a PC it became clear that it would only be possible to monitor information and change some basic settings that way. It did not allow any of the desired interactions with the system.

Message protocol

The final option was to do something with the message protocol used between the thermostat and the boiler. The Honeywell thermostat and Remeha boiler communicate using a protocol called Opentherm. Stories on the Internet gave the impression that interfacing with this protocol would be hard. You either need to buy a device like the Remeha gateway or build one yourself. The Remeha gateway is quite pricy and it converts the messages into its own undocumented format. So the chance of successfully interfering with the protocol in all the desired ways may be slim.

There is a schematic from Elektuur for an Opentherm monitor floating around on the web that can be used as a starting point for building your own gateway. But as the name indicates, that device is only designed to monitor the messages. It does not provide any means to modify the messages on the link.

DIY Gateway

So I sat down to design my own gateway, which turned out not to be nearly as hard as I expected from the horror stories on the internet.

After happily using my prototype built on perf board for a few years, I was contacted by someone who was interested in building the gateway as well, but wanted to have a proper printed circuit board made for it. Since most circuit board manufacturers will usually produce small batches rather than indivual boards, I wondered if I could have one of those extra boards, to which he agreed. This provided a nice opportunity to make some slight modifications to the design to fix some minor issues I found with the original device.

The whole circuit easily fits on a circuit board of less than 8 by 10 cm.

OpenTherm Gateway

The circuit was originally designed around a PIC16F88. Due to chip shortages in early 2022, the PIC16F88 was difficult to obtain. For that reason I started looking for a possible replacement and found the PIC16F1847. This chip can be configured in such a way that it is pin compatible with the PIC16F88. This means that it can be used with the existing PCB. Another advantage is that it has more flash memory and more RAM, which would allow new features to be added that will not fit in the PIC16F88. The architecture of the PIC16F1847 is quite different from the PIC16F88. So different firmware versions for the two chips had to be made. Make sure to obtain a firmware version that matches the chip in your device.

The features of both PICs are used in such a way that no code is needed to forward messages from the thermostat to the boiler and vice versa in monitor mode. However, with the appropriate firmware, the device is also able to create and send any desired message.


The firmware has been customized for the combination of a Remeha Avanta boiler with a Honeywell Chronotherm Modulation thermostat, but has proven to work with other combinations of boilers and thermostats as well. The current version provides the following functions:
  • Forward messages between the thermostat and the boiler
  • Report about the messages on the serial interface
  • Change the thermostat setpoint
  • Set the clock of the thermostat
  • Send the outside temperature to the thermostat
  • Smart power support
  • Support modulating and on/off thermostats, or even no thermostat at all
  • Read an outside temperature sensor
  • Control the domestic hot water option of the boiler
  • Obtain additional information from the boiler
  • Firmware updates through the serial interface


For questions and discussions about the OTGW and OTmonitor, please use the Opentherm Gateway Forum on Some people are abusing facilities available on the forum to send me email or private messages about subjects that could just as well be discussed in public on the forum. I simply don't have the time to provide support to individual OTGW users. So, be warned that such communication runs a high risk of being ignored.

I didn't publish this project to make money, but some people have inquired about a way to show their appreciation. So if you like, you can make a donation via paypal.