Tasmota MQTT IRHVAC Controller

@dedalusjinja Try with protocol/vendor in lower case. :slight_smile:

Hi! I did manage to get this working in the end, I just started from fresh with your custom component.

The only issue I have now is that Home Assistant’s HomeKit integration doesn’t map fan speed to HomeKit for HVAC devices. I’m trying to expose the fan speed services as a seperate fan entity to gain that control, but I’m new to HA and having trouble figuring out scripts etc. anyway, I’ll persevere.

1 Like

@stibbzy I’m glad to hear it is workig. :slight_smile: I just can’t help you with HomeKit. I’m not iPhone user. :slight_smile:

That’s ok. It’s not specifically an iPhone issue, I need to get a fan entity in Home Assistant that calls your component’s Fan services. Once the HA identity exists, it will flow through to HomeKit as do all other entities.

@stibbzy So may be you need something like this (change entity id with your Tasmota IRHVAC AC entity id and also the speeds):

fan:
  - platform: template
    fans:
      aircond_fan:
        friendly_name: "Aircond fan"
        value_template: >-
          {% if states('climate.daewoo_irhvac.state') != 'off' %}
             'on'
          {% else %}
             'off'
          {% endif %}
        speed_template: "{{ states('climate.daewoo_irhvac.fan_mode') }}"
        turn_on:
          service: climate.turn_on
          data:
            entity_id: climate.daewoo_irhvac
        turn_off:
          service: climate.turn_off
          data:
            entity_id: climate.daewoo_irhvac
        set_speed:
          service: climate.set_fan_mode
          data:
            entity_id: climate.daewoo_irhvac
            fan_mode: "{{ speed }}"
        speeds:
          - "min"
          - "low"
          - "medium"
          - "high"
          - "max"
          - "auto"
1 Like

@gh0s7 Thanks so much for that! I was working on something similar and this definitely helped! I had to end up using some scripts to translate Homekit speeds to TasmotaIR ones (eg Low in Homekit is Min). The only issue I have now is my Fan entity in HA doesn’t follow the state of the HVAC entity created from your plugin (e.g. turning off the HVAC entity doesn’t turn off the Fan entity). Is this something I should be able to fix with automations? The ones I’ve tried writing so far aren’t working:

- trigger:
  - entity_id: climate.owens_ac
    to: 'off'
    platform: state
  condition: []
  action:
  - service: script.turn_off_owens_ac_fan
  mode: single

script:

turn_off_owens_ac_fan:
    sequence:
      - service: climate.turn_off
        data:
          entity_id: climate.owens_ac

@stibbzy I think there is some problem with the fan integration. So far I havent found any way to turn it off or on using template fan. And as I see you can’t stop it with script and automation too, so I guess something is wrong with this fan integration. May be if you try with some custom fan integration (there might be some in github), it could work.

@gh0s7 Thanks for the advice, I’ll have a look around. Thanks for being so helpful :slight_smile:

1 Like

@gh0s7 A very very late reply, but I was clearly lacking the background, time and equipment to understand the issue well and have a meaning full reply.

With an other Echen IR Module, I’m connecting to an AC in another room and that one is behaving well. So that all looks good. I didn’t think that a “COOLIX” would be better researched than a SHARP AC, but I guess that’s the result of community support.

I’m looking into how I can contribute to the library and hopefully solve help make the library better.

Thanks for your reply and I appreciate the work you’ve done on the HA integration!

Hi expert,
Could you guide me how to control both AC and Fan from 1 tasmota MQTT IR ?
Thanks

@gh0s7 Hi again. I’ve managed to create a working fan template that successfully controls the fan functionality of your integration. It also maps to Homekit perfectly, so that’s a win!

I have one last issue. I can’t make changes to the mode or temperature from Home Assistant and have the change reflected in Homekit (although it does work the other way from Homekit to HA). This is because of how Homekit expected mode keys, (‘cooling’ vs ‘cool’).

Another member had the same issue with the MQTT Climate integration. He solved it by using an action_template to remap the received values: https://github.com/home-assistant/core/issues/25676#issuecomment-747494946

I have looked at your integration’s code, and it doesn’t appear to use the action_template feature. Is there any other way I can remap the mode values so that I overcome this issue? Cheers!

@stibbzy I can’t find any info or documentation about this action_template. It is possible to be achieved the same result, but this is a step forward, that requires lots of code changes. Also it requires a better understandig (at least for me) about how HomeKit works and its default values, also when and how it is supposed to take and send them. Currently I don’t know anything about HomeKit. Maybe in near future I’ll have to read more about it and try to implement its requirements. Anyway … Currently I don’t have any clue about it.

@gh0s7 No problem. Thanks for the reply anyway :slight_smile:

@Huy_Hoang_Pham For the AC you can follow the instructions on GitHub ir in the first post here. For the fan, if it can be controlled with IR, you could use scrips ‘ir_code’ or ‘ir_raw’, with the examples shown in first post and GitHub too. :slight_smile:

I would like to have a LED flash when a signal is received. Anyone tried this before and have any suggestions?

It’s possible change the language?

@met98 Sorry, this instegration does not support internationalization (language change). Maybe in future it would be possible, but for now it is not possible…

@kiwipaul Where do you want this LED to flash? I mean on the ESP board or somewhere else? Actually, the built in ESP8266 LED is flashing whenever IR signal is detected. :slight_smile: Other than the board itself it is possible with script or automation. Maybe it is also possible to attach some LED on the ESP board, the same way like the IR LED, but using different data pin, and using tasmota rules, detect if there is ‘irreceived’ and turn it on and off. :slight_smile: Also you can set this data pin as button or switch so you can power it on or of using rules, when IR is received. :slight_smile: I haven’t done that, but I think this is the easiest way, if the the built in LED is not visible. Actualy … I have one other idea, and it is even easier, if you want to make the IR transceiver to “blink”. You can use a small piece of fiber optic or transparent thin PVC (coffee stick for example), to connect the built in LED with a small hole in the case of the IR transceiver. :slight_smile: I know it works, because my old router uses this “technology” and also my Air Rifle too. :smiley:

Thanks for your thoughts. I have some spare WS2812 NeoPixel’s, the ones that look like fat LED’s, so I will have a go at setting one up under tasmota and have rules for different actions.

For optical feedback:
I use a cheapo Velleman VMA317 IR receiver which has built in red LED flashing when data is received- well seen in daylight also.
Best, JR