Interface firmware


The interface firmware turns the opentherm gateway into a serial to opentherm interface. This can be useful for experimenting with the opentherm protocol.


The firmware reports received opentherm messages to the serial interface in the normal way. But it doesn't forward them on its own from the master to the slave, or vice versa. It has to be told to transmit an opentherm message by specifying the message as 8 hexadecimal characters on the serial interface, followed by a carriage return. The firmware determines whether to send the message to the termostat or the boiler depending on bit 6 of the first byte. This bit is 0 in Master-to-Slave messages (the firmware sends the message to the boiler) and 1 in Slave-to-Master messages (the firmware sends the message to the thermostat).


The quickest way to get started using this interface is to write a small program that listens on the serial interface. On every BXXXXXXXX or TXXXXXXXX message received, strip the B or T and send the remaining 8 hexadecimal digits back over the serial line. Once that part is working, you can start adding code to manipulate the messages.

Serial commands

In addition to the hexadecimal messages, the firmware supports a limited and slightly modified set of serial commands compared to the gateway firmware:
LED A / LED B / LED C / LED D - These commands can be used to turn the LEDs on and off. Valid values for the state argument are: 1 to turn the LED on, and 0 to turn the LED off.
Gateway reset - Reset the gateway.
Print Report - The following items are currently defined:
  1. About opentherm interface (prints the welcome message)
  2. Tweaks. Reports the state of the ignore transitions setting.
  3. Report the reference voltage setting
Enable smart-power - Configure how the gateway should handle smart-power signals on the opentherm line toward the thermostat. The state argument controls whether smart-power support is enabled (EP=1) or disabled (EP=0).
Ignore Transitions - If the opentherm signal doesn't cleanly transition from one level to the other, the circuitry may detect multiple transitions when there should only be one. When this setting is off (IT=0), the gateway will report "Error 01" for those cases. With this setting on (IT=1), any rapid bouncing of the signal is ignored.
Voltage Reference - Change the reference voltage used as a threshold for the comparators. This configuration option is stored in non-volatile memory so it will persist even if the gateway has been powered off. The level must be specified as a single digit according to the following table:
0 1 2 3 4 5 6 7 8 9
0.625V 0.833V 1.042V 1.250V 1.458V 1.667V 1.875V 2.083V 2.292V 2.500V
The normal value is 3.
Debug Pointer - Set the debug pointer to a file register. If the debug pointer has been set to a value other than 00, the contents of the selected file register will be reported over the serial interface after each received OpenTherm message. The address must be specified as two hexadecimal digits. Setting the pointer to 00 switches off the debug reports.