So where I live we don’t have thermostats, just a reverse cycle Air conditioner/heat pump.
I am writing a python program that sits between home assistant and my Airtopia units (basically smart IR remotes) that control my AC units.
What’s been driving me nuts is tring to work out power control. So my Airtopia units separate power and mode. So If I request the “state” of the unit I get something back that looks like this
{“power”:“off”,“mode”:“heat”.“setpoint”:“20”,“temp”:“18.37”} (Its using celsius)
So with my old cloud solution I could ask my Google home to “Turn on the living room ac” and it would send
{“power”:“on”} to the unit and it would just change the power state turn the unit on and would keep the old setting, specifically the mode and setpoint
Is there a way I can replicate this in Homeassistant? I currently have my python program feeding home assistant data but I don’t know how to integrate a power toggle into lovelace thermostat card as it appears it has an “off” function but that’s a mode, which my unit has separate power from mode.
So in my current cloud setup I can change the unit to “heat” and that would set the unit to heat, but wont turn it on until the “on” power command is sent.
I would like to eventually integrate this with Google home so I would like to keep power and mode separated.
Also as a side note, Im stuck on how to get MQTT to read Horizontal and Vertical swing as separate items also I have “powerful” and “quiet” modes, which are on:off items that basically change the fan speed, but they are separate entities from the fan speed. So help integrating those would be great.
This is my current config in in MQTT.yaml which my configuration.yaml points to for MQTT.
climate:
- name: "Living Room AC"
unique_id: living_room_ac
retain: "true"
temperature_unit: "C"
modes:
- "cool"
- "heat"
- "auto"
- "fan_only"
- "dry"
fan_modes:
- "1"
- "2"
- "3"
- "4"
- "auto"
min_temp: "12"
max_temp: "32"
temp_step: "1"
# vswing:
# - "auto"
# - "off"
# hswing:
# - "auto"
# - "off"
# powerful:
# - "on"
# - "off"
# quiet:
# - "on"
# - "off"
# econo:
# - "on"
# - "off"
mode_command_template: >-
{% if value == 'cool' %}
cool
{% elif value == 'heat' %}
heat
{% elif value == 'auto' %}
auto
{% elif value == 'fan_only' %}
fan
{% elif value == 'dry' %}
dry
{% else %}
auto
{% endif %}
mode_state_topic: "homeassistant/climate/LivingRoom_AC/mode"
mode_command_topic: "homeassistant/climate/LivingRoom_AC/modeset"
fan_mode_state_topic: "homeassistant/climate/LivingRoom_AC/fan"
fan_mode_command_topic: "homeassistant/climate/LivingRoom_AC/fanset"
# vswing_state_topic: "homeassistant/climate/LivingRoom_AC/vswing"
# vswing_command_topic: "homeassistant/climate/LivingRoom_AC/vswingset"
# hswing_state_topic: "homeassistant/climate/LivingRoom_AC/hswing"
# hswing_command_topic: "homeassistant/climate/LivingRoom_AC/hswingset"
# powerful_state_topic: "homeassistant/climate/LivingRoom_AC/powerful"
# powerful_command_topic: "homeassistant/climate/LivingRoom_AC/powerfulset"
# quiet_state_topic: "homeassistant/climate/LivingRoom_AC/quiet"
# quiet_command_topic: "homeassistant/climate/LivingRoom_AC/quietset"
# econo_state_topic: "homeassistant/climate/LivingRoom_AC/econo"
# econo_command_topic: "homeassistant/climate/LivingRoom_AC/econoset"
temperature_state_topic: "homeassistant/climate/LivingRoom_AC/setpoint"
temperature_command_topic: "homeassistant/climate/LivingRoom_AC/setpointset"
current_temperature_topic: "homeassistant/climate/LivingRoom_AC/temp"
another side note: I’m a complete novice when it comes to Home Assistant and Python. I have spent 3+ hours each night for the past 2 weeks to get this far