Connect ESP8266 directly to a Remeha Avanta V1 P3 CV/Boiler to read data using PHP.
The PHP code uses an Adafruit Huzzah ESP8266 to connect to and read data from a Remeha Avanta V1 P3 boiler. The Huzzah ESP8266 was chosen as it is a 5VDC device and does not require any level shifter or additional circuits to deal with the higher voltage.
- Adafruit Huzzah ESP8266 flashed with the ESP-Link firmware/software (https://learn.adafruit.com/adafruit-huzzah-esp8266-breakout/overview)
- Domoticz (https://www.domoticz.com/)
- Webserver (See packages, you can install it on your Domoticz RPi)
- Packages (sudo apt install apache2 php7.3 libapache2-mod-php7.3 php7.3-cli php7.3-fpm php7.3-json php7.3-zip php7.3-mbstring php7.3-curl php7.3-xml php7.3-json)
Before you start, you will need a external 5v power supply with the Avanta since it can't provide enough power. Using the VDC (pin4) to power your Adafruit will boot loop your boiler since it can't provide enough power.
Connect to the Remeha X13 connector using a 4P4C (RJ10) connector with the following pinouts:
Remeha >>>>>>>>>> ESP8266
- Pin1 (GND)........> GND
- Pin2 (RX).........> TX
- Pin3 (TX).........> RX
- Pin4 (VDC)........> Do not use (prevents boot loops of the boiler)
I'm not responsible for any damage in any way.
- Add a Dummy under the Hardware tab
- Create Virtual Sensor at the Hardware tab (easiest is to use the Domoticz Devices naming of remehe.ini)
- Change the IDX numbers in remeha.ini according to the virtual sensor IDX's
- Run "php7.3 /var/www/html/remeha/remeha-counters.php" and "php7.3 /var/www/html/remeha/remeha-samples.php" on your webserver (or create a crontab to automate)
- Domoticz should now be updated with the data
Currently this is a 'read only' script and provides the following functionality:
- Connects ESP to Avanta (set Baudrate of ESP-Link to 9600 8N1)
- Sends Hex to Avanta and reads the responses (for "Sample Data", "Counter Data" and "Parameters")
- Maps response to more 'logical' variables
- Translates various 'bits' to provide correct messages
- Writes information received to Domoticz server using cURL
- The remeha-xxxxx.php scripts can be run from within a browser, while the remeha.php script is best run as a daemon or in the background
Q: My Boiler is not providing hot water anymore, and shows an error A: This mostly happens when someone is using the VDC (pin4) of the boiler to power the Adafruit. Remove the VDC from the Adafruit. Now press and hold R on your Boiler, it will reset and reboot.
Q: I have no idea whats wrong! A: Create an issue, i might be able to help
juanelc - Creating and testing the scripts for Avanta V1 P3