├── assets ├── Example_1.png ├── Example_2.png └── Dehumidifier_Animation.gif ├── README.md └── Dehumidifier_Comfee_Card.yaml /assets/Example_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MiguelCosta/Dehumidifier_Comfee_Card/HEAD/assets/Example_1.png -------------------------------------------------------------------------------- /assets/Example_2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MiguelCosta/Dehumidifier_Comfee_Card/HEAD/assets/Example_2.png -------------------------------------------------------------------------------- /assets/Dehumidifier_Animation.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MiguelCosta/Dehumidifier_Comfee_Card/HEAD/assets/Dehumidifier_Animation.gif -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Dehumidifier Comfee Lovelace Card - Home Assistant 2 | 3 | I have the Comfee [Deshumidificador MDDF-20DEN7-WF 20L/day](https://www.amazon.es/-/pt/gp/product/B07MSL8YN7) and I created a lovelace card for Home Assistant from [MauricioXavier13](https://github.com/MauricioXavier13/Dehumidifier_Comfee_Card) example but using [homeassistant-midea-dehumidifier-lan](https://github.com/nbogojevic/homeassistant-midea-dehumidifier-lan) integration. 4 | 5 | ![animation](/assets/Dehumidifier_Animation.gif) 6 | 7 | ## Home Assistant Cards, Configuration and information 8 | 9 | ### Pre-requisites 10 | 11 | - HACS Custom integration 12 | - homeassistant-midea-dehumidifier-lan | https://github.com/nbogojevic/homeassistant-midea-dehumidifier-lan 13 | 14 | - HACS Custom-Cards 15 | - custom:multiple-entity-row | https://github.com/benct/lovelace-multiple-entity-row 16 | - custom:button-card | https://github.com/custom-cards/button-card 17 | - custom:text-divider-row | https://github.com/iantrich/text-divider-row 18 | - custom:paper-buttons-row | https://github.com/jcwillox/lovelace-paper-buttons-row 19 | - card-tools | https://github.com/thomasloven/lovelace-card-tools 20 | 21 | ### Use the card 22 | 23 | If you are using the same dehumidifier model/brand you just need to copy [all the card code](Dehumidifier_Comfee_Card.yaml) and replace the entity_id by your own. 24 | 25 | Entities to replace: 26 | 27 | - `humidifier.dehumidifier_suite` 28 | - `sensor.dehumidifier_suite_humidity` 29 | - `binary_sensor.dehumidifier_suite_defrosting` 30 | - `sensor.dehumidifier_suite_temperature` 31 | - `binary_sensor.dehumidifier_suite_tank_full` 32 | - `binary_sensor.dehumidifier_suite_replace_filter` 33 | - `fan.dehumidifier_suite_fan` 34 | 35 | ### Examples 36 | 37 | ![example1](/assets/Example_1.png) 38 | ![example1](/assets/Example_2.png) 39 | 40 | ### Changelog 41 | 42 | #### 2022-01-20 43 | 44 | - Update `Silent` to `Low` 45 | - Update `Turbo` to `High` 46 | - `replace_filter` was remove because it not supported by midea dehumidifier (https://github.com/nbogojevic/homeassistant-midea-air-appliances-lan/releases/tag/v0.6.0-beta) 47 | -------------------------------------------------------------------------------- /Dehumidifier_Comfee_Card.yaml: -------------------------------------------------------------------------------- 1 | ######################## 2 | #### Lovelace Card ##### 3 | ######################## 4 | 5 | type: vertical-stack 6 | title: "Dehumidifier Suite \U0001F4A6" 7 | cards: 8 | - type: entities 9 | show_header_toggle: false 10 | entities: 11 | - entity: humidifier.dehumidifier_suite 12 | toggle: false 13 | type: custom:multiple-entity-row 14 | name: Humidity 15 | icon: mdi:water-percent 16 | state_header: State 17 | entities: 18 | - attribute: humidity 19 | name: Target 20 | unit: '%' 21 | - entity: sensor.dehumidifier_suite_humidity 22 | name: Current 23 | - entity: binary_sensor.dehumidifier_suite_defrosting 24 | toggle: false 25 | type: custom:multiple-entity-row 26 | name: Status 27 | icon: mdi:format-list-bulleted-type 28 | state_header: Defrosting 29 | entities: 30 | - entity: sensor.dehumidifier_suite_temperature 31 | name: Temperature 32 | header: 33 | type: picture 34 | image: >- 35 | https://www.vazamentos.info/wp-content/uploads/2019/06/Como-acabar-com-a-condensacao.jpg 36 | - type: horizontal-stack 37 | cards: 38 | - type: custom:button-card 39 | tap_action: 40 | action: call-service 41 | service: humidifier.toggle 42 | service_data: 43 | entity_id: humidifier.dehumidifier_suite 44 | entity_id: humidifier.dehumidifier_suite 45 | entity: humidifier.dehumidifier_suite 46 | extra_styles: | 47 | @keyframes bounce { 48 | 0%, 20%, 50%, 80%, 100% { transform: translateX(0); } 49 | 40% { transform: translateX(-15px); } 50 | 60% { transform: translateX(-10px); } 51 | } 52 | name: Dehumidifier 53 | icon: mdi:air-humidifier 54 | show_state: true 55 | show_icon: true 56 | show_name: false 57 | styles: 58 | card: 59 | - background-color: red 60 | state: 61 | - value: 'on' 62 | icon: mdi:tailwind 63 | styles: 64 | card: 65 | - background-color: limegreen 66 | icon: 67 | - icon: mdi:tailwind 68 | - color: white 69 | - animation: bounce 2s infinite 70 | - type: custom:button-card 71 | entity: binary_sensor.dehumidifier_suite_tank_full 72 | name: Empty 73 | show_icon: true 74 | show_name: true 75 | state: 76 | - value: 'on' 77 | icon: mdi:beaker-alert 78 | name: Full 79 | styles: 80 | card: 81 | - background-color: orange 82 | - animation: blink 2s infinite 83 | - operator: default 84 | icon: mdi:beaker-outline 85 | - type: custom:button-card 86 | entity: fan.dehumidifier_suite_fan 87 | show_icon: true 88 | show_name: true 89 | state: 90 | - operator: template 91 | value: | 92 | [[[ 93 | return (states['fan.dehumidifier_suite_fan'].attributes.preset_mode === 'High' ) && states['humidifier.dehumidifier_suite'].state === 'on' 94 | ]]] 95 | icon: mdi:fan 96 | color: yellow 97 | name: Turbo 98 | styles: 99 | icon: 100 | - animation: 101 | - rotating 0.5s linear infinite 102 | card: 103 | - color: yellow 104 | - operator: template 105 | value: | 106 | [[[ 107 | return (states['fan.dehumidifier_suite_fan'].attributes.preset_mode === 'Medium' ) && states['humidifier.dehumidifier_suite'].state === 'on' 108 | ]]] 109 | icon: mdi:fan 110 | color: yellow 111 | name: Medium 112 | styles: 113 | icon: 114 | - animation: 115 | - rotating 1s linear infinite 116 | card: 117 | - color: yellow 118 | - operator: template 119 | value: | 120 | [[[ 121 | return (states['fan.dehumidifier_suite_fan'].attributes.preset_mode === 'Low' ) && states['humidifier.dehumidifier_suite'].state === 'on' 122 | ]]] 123 | icon: mdi:fan 124 | color: yellow 125 | name: Low 126 | styles: 127 | icon: 128 | - animation: 129 | - rotating 2s linear infinite 130 | card: 131 | - color: yellow 132 | - operator: default 133 | icon: mdi:fan 134 | color: white 135 | name: "Off" 136 | - type: entities 137 | show_header_toggle: false 138 | entities: 139 | - type: custom:text-divider-row 140 | text: Select Mode 141 | - type: custom:paper-buttons-row 142 | buttons: 143 | - tap_action: 144 | action: call-service 145 | service: humidifier.set_mode 146 | service_data: 147 | entity_id: humidifier.dehumidifier_suite 148 | mode: Set 149 | icon: mdi:water-percent 150 | layout: icon_name 151 | name: Target 152 | style: 153 | button: 154 | background-color: > 155 | {% if is_state_attr('humidifier.dehumidifier_suite', 'mode', 156 | 'Set' ) and is_state('humidifier.dehumidifier_suite', 'on') 157 | %} 158 | limegreen 159 | {% else%} 160 | 161 | {% endif %} 162 | color: > 163 | {% if is_state_attr('humidifier.dehumidifier_suite', 'mode', 164 | 'Set' ) and is_state('humidifier.dehumidifier_suite', 'on') 165 | %} 166 | white 167 | {% else%} 168 | 169 | {% endif %} 170 | border-radius: 10px 171 | opacity: 1 172 | - icon: mdi:robot 173 | tap_action: 174 | action: call-service 175 | service: humidifier.set_mode 176 | service_data: 177 | entity_id: humidifier.dehumidifier_suite 178 | mode: Smart 179 | layout: icon_name 180 | name: Smart 181 | style: 182 | button: 183 | background-color: > 184 | {% if is_state_attr('humidifier.dehumidifier_suite', 'mode', 185 | 'Smart' ) and is_state('humidifier.dehumidifier_suite', 'on') 186 | %} 187 | limegreen 188 | {% else%} 189 | 190 | {% endif %} 191 | color: > 192 | {% if is_state_attr('humidifier.dehumidifier_suite', 'mode', 193 | 'Smart' ) and is_state('humidifier.dehumidifier_suite', 'on') 194 | %} 195 | white 196 | {% else%} 197 | 198 | {% endif %} 199 | border-radius: 10px 200 | opacity: 1 201 | - icon: mdi:autorenew 202 | name: Continuous 203 | layout: icon_name 204 | tap_action: 205 | action: call-service 206 | service: humidifier.set_mode 207 | service_data: 208 | entity_id: humidifier.dehumidifier_suite 209 | mode: Continuous 210 | style: 211 | button: 212 | background-color: > 213 | {% if is_state_attr('humidifier.dehumidifier_suite', 'mode', 214 | 'Continuous' ) and is_state('humidifier.dehumidifier_suite', 215 | 'on') %} 216 | limegreen 217 | {% else%} 218 | 219 | {% endif %} 220 | color: > 221 | {% if is_state_attr('humidifier.dehumidifier_suite', 'mode', 222 | 'Continuous' ) and is_state('humidifier.dehumidifier_suite', 223 | 'on') %} 224 | white 225 | {% else%} 226 | 227 | {% endif %} 228 | border-radius: 10px 229 | opacity: 1 230 | - icon: mdi:tshirt-crew 231 | name: Dryer 232 | layout: icon_name 233 | tap_action: 234 | action: call-service 235 | service: humidifier.set_mode 236 | service_data: 237 | entity_id: humidifier.dehumidifier_suite 238 | mode: Dry 239 | style: 240 | button: 241 | background-color: > 242 | {% if is_state_attr('humidifier.dehumidifier_suite', 'mode', 243 | 'Dry' ) and is_state('humidifier.dehumidifier_suite', 'on') 244 | %} 245 | limegreen 246 | {% else%} 247 | 248 | {% endif %} 249 | color: > 250 | {% if is_state_attr('humidifier.dehumidifier_suite', 'mode', 251 | 'Dry' ) and is_state('humidifier.dehumidifier_suite', 'on') 252 | %} 253 | white 254 | {% else%} 255 | 256 | {% endif %} 257 | border-radius: 10px 258 | opacity: 1 259 | - type: custom:text-divider-row 260 | text: Select Fan Speed 261 | - type: custom:paper-buttons-row 262 | buttons: 263 | - icon: mdi:fan-speed-1 264 | name: Low 265 | layout: icon_name 266 | tap_action: 267 | action: call-service 268 | service: fan.set_preset_mode 269 | service_data: 270 | entity_id: fan.dehumidifier_suite_fan 271 | preset_mode: Low 272 | style: 273 | button: 274 | background-color: > 275 | {% if is_state_attr('fan.dehumidifier_suite_fan', 276 | 'preset_mode', 'Low' ) and 277 | is_state('humidifier.dehumidifier_suite', 'on') %} 278 | limegreen 279 | {% else%} 280 | 281 | {% endif %} 282 | color: > 283 | {% if is_state_attr('fan.dehumidifier_suite_fan', 284 | 'preset_mode', 'Low' ) and 285 | is_state('humidifier.dehumidifier_suite', 'on') %} 286 | white 287 | {% else%} 288 | 289 | {% endif %} 290 | border-radius: 10px 291 | opacity: 1 292 | - icon: mdi:fan-speed-2 293 | name: Medium 294 | layout: icon_name 295 | tap_action: 296 | action: call-service 297 | service: fan.set_preset_mode 298 | service_data: 299 | entity_id: fan.dehumidifier_suite_fan 300 | preset_mode: Medium 301 | style: 302 | button: 303 | background-color: > 304 | {% if is_state_attr('fan.dehumidifier_suite_fan', 305 | 'preset_mode', 'Medium' ) and 306 | is_state('humidifier.dehumidifier_suite', 'on') %} 307 | limegreen 308 | {% else%} 309 | 310 | {% endif %} 311 | color: > 312 | {% if is_state_attr('fan.dehumidifier_suite_fan', 313 | 'preset_mode', 'Medium' ) and 314 | is_state('humidifier.dehumidifier_suite', 'on') %} 315 | white 316 | {% else%} 317 | 318 | {% endif %} 319 | border-radius: 10px 320 | opacity: 1 321 | - icon: mdi:fan-speed-3 322 | name: High 323 | layout: icon_name 324 | tap_action: 325 | action: call-service 326 | service: fan.set_preset_mode 327 | service_data: 328 | entity_id: fan.dehumidifier_suite_fan 329 | preset_mode: High 330 | style: 331 | button: 332 | background-color: > 333 | {% if is_state_attr('fan.dehumidifier_suite_fan', 334 | 'preset_mode', 'High' ) and 335 | is_state('humidifier.dehumidifier_suite', 'on') %} 336 | limegreen 337 | {% else%} 338 | 339 | {% endif %} 340 | color: > 341 | {% if is_state_attr('fan.dehumidifier_suite_fan', 342 | 'preset_mode', 'High' ) and 343 | is_state('humidifier.dehumidifier_suite', 'on') %} 344 | white 345 | {% else%} 346 | 347 | {% endif %} 348 | border-radius: 10px 349 | opacity: 1 350 | --------------------------------------------------------------------------------