Просмотр исходного кода

Added support for Pilot Wire Thermostat (#4040)

* Create pilot_rp5_bath_thermostat_min.yaml

* Migrate to new entities schema and fix yamllint/style issues

* Fixed left-over linting issues

* Removed icon and fixed linting issue

* Removed all alternatives: keys from the DPS entries

* Refactored Pilot RP5 minimal thermostat config based on review feedback

- Change device name to generic "Thermostat"
- Split product name into manufacturer and model fields
- Replace explicit climate entity name/icon with translation_key: thermostat
- Consolidate HVAC mode mappings and hide redundant heat mappings
- Remove duplicate temperature unit (keep only on target temperature)
- Replace Child Lock name/icon with translation_key: child_lock

* fix (pilot_rp5_baththermostat) rename file without min suffix

The min suffix may be indicating that initial submission is a minimal implementation, but if the config is expanded in future it will become misleading.

PR #4040

---------

Co-authored-by: Jason Rumney <make-all@users.noreply.github.com>
Rick Bergmans 4 месяцев назад
Родитель
Сommit
c4f676a01b
1 измененных файлов с 71 добавлено и 0 удалено
  1. 71 0
      custom_components/tuya_local/devices/pilot_rp5_baththermostat.yaml

+ 71 - 0
custom_components/tuya_local/devices/pilot_rp5_baththermostat.yaml

@@ -0,0 +1,71 @@
+name: Thermostat
+products:
+  - id: c03zek9b5daz7omr
+    manufacturer: "Pilot"
+    model: "RP5"
+
+entities:
+  - entity: climate
+    translation_key: thermostat
+    dps:
+      # --- HVAC mode (off / heating / auto) ---
+      - id: 101
+        type: string
+        name: hvac_mode
+        mapping:
+          - dps_val: "Standby"
+            value: "off"
+          - dps_val: "Programming"
+            value: "auto"
+          - dps_val: "Comfort"
+            value: "heat"
+          - value: "heat"
+            hidden: true
+
+      # --- Target temperature (°C) ---
+      - id: 125
+        type: integer
+        name: temperature
+        range:
+          min: 50
+          max: 300
+        mapping:
+          - scale: 10
+        unit: "°C"
+
+      # --- Current temperature (°C) ---
+      - id: 116
+        type: integer
+        name: current_temperature
+        range:
+          min: -300
+          max: 900
+        mapping:
+          - scale: 10
+
+      # --- Preset modes (via same DP 101) ---
+      - id: 101
+        type: string
+        name: preset_mode
+        mapping:
+          - dps_val: "ECO"
+            value: "eco"
+          - dps_val: "Anti_forst"
+            value: "away"
+          - dps_val: "Comfort"
+            value: "comfort"
+          - dps_val: "Comfort_1"
+            value: "comfort_1"
+          - dps_val: "Comfort_2"
+            value: "comfort_2"
+          - dps_val: "Thermostat"
+            value: "manual"
+          - dps_val: "Programming"
+            value: "program"
+
+  - entity: lock
+    translation_key: child_lock
+    dps:
+      - id: 102
+        type: boolean
+        name: lock