Convert common irsend to specific vendor #1982
-
Hello I just bought a new ac unit and until now I realize it has it’s technical difficulties , it’s a whirlpool unit and according to my reading in the repo I need to toggle the power, however in my previous unit I was using the generic implementation and was working, I was wondering if I can input the basics of the state from the generic into the whirlpool class just to populate the already formed values. I am trying to write the less code possible to be able to maintain it clean if possible greetings |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
Can you expand on what you mean when you say "I was using the generic implementation"? I'm having difficulty understanding what your trying to do, and what you have previously done. |
Beta Was this translation helpful? Give feedback.
-
Sure, I have this code:
I would like to use the already configured state to feed the IRWhirlpoolAc class, something similar like this
But in the inverse from common to IRWhirpoolAc |
Beta Was this translation helpful? Give feedback.
Unfortunately, there doesn't exist a convenient method to convert a
stdAc::state_t
into a specificIRWhirlpoolAC
object state. There just hasn't been a pressing need for it, or a practical use case for it.The best I can suggest is copy the code from:
IRremoteESP8266/src/IRac.cpp
Lines 2731 to 2768 in e52495f