This project is unmaintained. Check out https://github.com/dannerph/esphome_vitoconnect for a more advanced component.
Example code for using an ESP32 or ESP8266 as a sensor for Viessmann optolink.
Tested with OptoLink ESP32 adapter from here: https://github.com/openv/openv/wiki/Bauanleitung-ESP32-Adafruit-Feather-Huzzah32-and-Proto-Wing
Built on top of https://github.com/bertmelis/VitoWifi