This external component provides a way retrieve and control Computherm Q series thermostats. The RF receiver allows up to four individual devices. Existing devices can either be monitored as sensors or via manual pairing (in progress) you can add virtual zones that control the boiler separately. Computherm Q8
The communication with the RF receiver is accomplised via 868.35 MHz in a custom protocol originally decoded by @denxhun in his Arduino library and proposal of the reference hardware. Inspiration came from flogi diyiot blog.
Bunding into ESPHome was inspired by @nistvan86 in his CC1101 hardware alternative.
Communication with the device is done through a receiver and an transmitter module. They are not connected, so theoretically sensor and switch module works independently.
# Example configuration entry
external_components:
- source: github://afarago/esphome_component_computhermqrf
components: [ computhermqrf ]
computhermqrf:
receiver_pin: D1
transmitter_pin: D2
binary_sensor:
- platform: computhermqrf
name: "Zone 1"
code: 0x12347
- platform: computhermqrf
name: "Zone 2"
code: 0x1234B
switch:
- platform: computhermqrf
name: "Zone 3"
code: 0x12343
button:
- platform: computhermqrf
mode: "pair"
name: "Start pairing"
- receiver_pin (Optional): Specify the receiver pin.
- transmitter_pin (Optional): Specify the transmitter pin.
- code (Required, string): Specify the 5 digit hex code associated with the zone.
- name (Optional, string): Specify the zone name.
- All other options from Binary Sensor.
- code (Required, string): Specify the 5 digit hex code associated with the zone.
- name (Optional, string): Specify the zone name.
- turn_on_watchdog_interval (Optional, Time): Specify how long the switch can stay turned on after the last write_state call arrived for the switch component in milliseconds. This can be used for example in conjunction with the keep_alive setting of Home Assistant's generic thermostat component to add an additional safe guard against the crash of HA and to prevent excessive heating costs. Defaults to 30 minutes.
- resend_interval (Optional, Time): Specify how often to repeat the last state in milliseconds. Since this is a simplex protocol, there's no response arriving from the receiver and we need to compensate for corrupt or lost messages by repeating them. Defaults to 1 minute.
- All other options from Switch.
- mode (Required, string): must be "pair"
- All other options from Button.
Special pairing button and service to add a new virtual zone with details below.
While hardware thermostats will turn off heating by periodically monitoring the temperature the virtual appliance will not do so, therefore it is advised to to create and automation to turn it off automatically after a period of time or on HA or MQTT disconnect.
esphome:
...
on_shutdown:
then:
- switch.turn_off: switch_zone3
- delay: 2s
switch:
- platform: computhermqrf
name: "Zone 3 extra"
code: 0x12343
id: switch_zone3
turn_on_watchdog_interval: 30min
OR
esphome:
...
on_shutdown:
then:
- switch.turn_off: switch_zone3
- delay: 2s
switch:
- platform: computhermqrf
name: "Zone 3 extra"
code: 0x12343
id: switch_zone3
on_turn_on:
if:
condition:
for:
time: 30min
condition:
switch.is_on: switch_zone3
then:
- logger.log: Auto turn off switch_zone3
- switch.turn_off: switch_zone3
You need the following list of hardware
- ESP 8266 Wemos D1 mini
- RF Receiver: HopeRF RFM217W-868S1
- RF Transmitter: HopeRF RFM117W-868S1
- (optional) DHT22 Digital Temperature and Humidity Temperature Sensor
Connections:
D1_MINI RFM117W RFM217W DHT22 10K_Ohm_pullup_resistor
=========================================================
3.3V VCC VCC VCC(pin1) PIN2
GND GND GND GND(pin4) -
D1 - DATA - -
D2 DATA - - -
D3 - - DATA(pin2) PIN1
I have created a nice wemos shield as well for my home automation purposes.
Computherm QRF Codes are 5 half byte codes, represented as hex code. The codes are randomly generated and assigned upon a pairing process. Without configuring any binary_sensors you still see all ongoing traffic n the debug log. You check which is your zone code before setting up a binary_sensor.
[D][computhermqrf:069]: Message received - Unregistered - thermostat: ABCD7, command: OFF
For virtual zones used for switches you can come up with any arbitrary code. It seens that the first 4 bytes are arbitrary and the last half byte is
- zone 1 --> 0111 (...7)
- zone 2 --> 1011 (...B)
- zone 3 --> 0011 (...3)
- zone 4 --> 1101 (...D)
Creating a virtual zone lets you take control of your boiler manually or via any automation through an ESPHome Switch component.
Steps:
-
Come up with any arbitrary code -hopefully not used by the neighbours- taking into consideration which zone you wish to pair and control. In our example we will use zone 4 and our code will be 0x1111D.
-
Using HomeAssistant
- On the Q8RF receiver long press the desired zone button, so it will start blinking
- Go to Home Assistant's Developer tools → Services and select the service ESPHome: <NODE_NAME>_computhermqrf_pair . This will start the pairing and the RF receiver will learn the zone code and immediately stop blinking.
-
Not using HomeAssistant
- Add a new pairing button to the configuration and upload.
switch: - platform: computhermqrf name: "Zone 4 extra pairing" code: 0x1111D pairing_mode: true button: - platform: computhermqrf mode: "pair" name: "Start pairing"
- On the Q8RF receiver long press the desired zone button, so it will start blinking
- Using the web UI simply push the pairing button. This will start the pairing and the RF receiver will learn the zone code and immediately stop blinking.
- (Optional) You can remove pairing button from the config and recompile and upload.
- Add a new pairing button to the configuration and upload.
Refer to the Q8RF manual for the pairing process, "9.2 Putting the receiver unit into operation".