The IRsend class has the very useful method IRsend::send() which lets you send commands to many different devices with just one function. Anyway it supports few types of devices (no Panasonic,...). In my opinion it would be great to add all the not-AC devices to this method and add a similar method for all the AC devices with arguments like temperature, mode, fan, type,...
I'll update send() for all the simple protocols. Creating a generic AC one is tricky and a lot more effort, so it won't happen any time soon.
I'll update send() for all the simple protocols. Creating a generic AC one is tricky and a lot more effort, so it won't happen any time soon.
Can we dive a little on the generic AC one? I was thinking about polymorphism but that seems a no-go as @devyte metioned here
The main use case I have in mind would be the mqttserver example or the EspEasy tx plugin
You're not the only one who want's it. I've had a couple of attempts to add it, and each time the code became a horrible mess. I want to do it in such a way that it works with Home Assistant's "climate" feature and/or present a JSON interface etc.
@glmnet There are a number of issues. Mainly that not all A/Cs operate the same way. some have special On/Off messages, etc etc. I need to come up with a way that is generic and supports most of the A/C protocols with as much of the features as I can, and maybe a way of supporting other features that some models don't etc.
So, It hasn't been forgotten. But hey, as usual, feel free to contribute a PR/solution. ;-)
V2.5.6 has just been release which includes the changes/improvements mentioned.
FYI, this (generic a/c) has been included in the newly released v2.6.0 of the library.
Fantastic!