esphome: name: vbus-solar-heizung esp32: board: esp32dev framework: type: arduino advanced: minimum_chip_revision: "3.1" sram1_as_iram: true wifi: ssid: "WLan" password: "passwort" api: ota: - platform: esphome logger: level: VERY_VERBOSE # ============================================================ # UART # ============================================================ uart: # DeltaSol SLTV - id: uart_deltasol rx_pin: number: GPIO16 inverted: true baud_rate: 9600 data_bits: 8 parity: NONE stop_bits: 1 debug: # ============================================================ # VBus # ============================================================ vbus: - id: vbus_deltasol uart_id: uart_deltasol # ============================================================ # ROHDATEN - zum Debuggen # ============================================================ text_sensor: - platform: template name: "DeltaSol SLTV Rohdaten" id: deltasol_raw icon: "mdi:alpha-d-box" # ============================================================ # SENSOREN # ============================================================ sensor: # ========================================================== # DELTASOL SLTV # # Source: 1001 # Destination: 0010 # Command: 0100 # ========================================================== - platform: vbus vbus_id: vbus_deltasol model: custom dest: 0x0010 source: 0x1001 command: 0x0100 sensors: # -------------------------------------------------------- # S1 - Kollektor # Offset 4/5 # -------------------------------------------------------- - id: deltasol_s1 name: "DeltaSol S1 Kollektor" device_class: temperature state_class: measurement unit_of_measurement: "°C" accuracy_decimals: 1 lambda: |- return ((x[5] << 8) | x[4]) * 0.1f; # -------------------------------------------------------- # S2 - Speicher oben # Offset 6/7 # -------------------------------------------------------- - id: deltasol_s2 name: "DeltaSol S2 Speicher oben" device_class: temperature state_class: measurement unit_of_measurement: "°C" accuracy_decimals: 1 lambda: |- return ((x[7] << 8) | x[6]) * 0.1f; # -------------------------------------------------------- # S4 - Speicher unten # Offset 10/11 # -------------------------------------------------------- - id: deltasol_s4 name: "DeltaSol S4 Speicher unten" device_class: temperature state_class: measurement unit_of_measurement: "°C" accuracy_decimals: 1 lambda: |- return ((x[11] << 8) | x[10]) * 0.1f; # -------------------------------------------------------- # R1 - Pumpe # -------------------------------------------------------- - id: deltasol_r1 name: "DeltaSol R1 Pumpe" unit_of_measurement: "%" state_class: measurement accuracy_decimals: 0 lambda: |- return x[30]; # -------------------------------------------------------- # R2 - 3-Wegeventil # # An/Aus wird als 0/100 % behandelt. # -------------------------------------------------------- - id: deltasol_r2 name: "DeltaSol R2 3-Wegeventil" unit_of_measurement: "%" state_class: measurement accuracy_decimals: 0 lambda: |- return x[31] > 0 ? 100.0f : 0.0f; # -------------------------------------------------------- # Debug-Rohdaten # -------------------------------------------------------- - id: deltasol_trigger internal: true lambda: |- std::string hex_str; char buf[4]; for (uint8_t b : x) { snprintf(buf, sizeof(buf), "%02X ", b); hex_str += buf; } id(deltasol_raw).publish_state(hex_str); return 0.0f;