No audible beep when sending commands to TAC-12/XA73
During my iFeel function research on my TCL TAC-12/XA73, I found out that there is a simple way to avoid the AC from beeping when sending commands to it.
Seems that the quiet mode setting is not included in the message when it is a 'kTcl112AcNormal' message. If you do include it, and set it to False, the AC wil not beep. Probably because it thinks its a iFeel update message from the remote control.
I tested this by editing "ir_Tcl.cpp" and adding "result.quiet = false;" to the kTcl112AcNormal message. This will change bit 3 in Byte 5 to 0.
No more beeeps.... Yeeaah!!
stdAc::state_t IRTcl112Ac::toCommon(const stdAc::state_t *prev) const { stdAc::state_t result{}; // Start with the previous state if given it. if (prev != NULL) result = *prev; result.protocol = decode_type_t::TCL112AC; result.model = getModel(); result.quiet = getQuiet(result.quiet); // The rest only get updated if it is a "normal" message. if (.MsgType == kTcl112AcNormal) { result.power = .Power; result.mode = toCommonMode(.Mode); result.quiet = false; result.celsius = true; result.degrees = getTemp(); result.fanspeed = toCommonFanSpeed(.Fan); result.swingv = toCommonSwingV(_.SwingV); result.swingh = _.SwingH ? stdAc::swingh_t::kAuto : stdAc::swingh_t::kOff; result.turbo = _.Turbo; result.filter = _.Health; result.econo = _.Econo; result.light = getLight(); } // Not supported. result.clean = false; result.beep = false; result.sleep = -1; result.clock = -1; return result; }
Yep, I need some help with this. It seems that to disable the audible beep with every command I need to set the Quiet bit to 0 in the kTcl112AcNormal messages. My solutions to just add "result.quiet = false;" to the kTcl112AcNormal in "stdAc::state_t IRTcl112Ac::toCommon" does not seem to actually set the bit to 0.
Tried different approches to do this but for now the only thing that actually seems to work is by changing the bit via the 'default' state in stateReset(). Changed Byte 5 from 0x24 to 0x04. In my ESP32/Arduino project I then do a ac.stateReset() before changing settings and sending the command.
It would be nice if I had a better way to set the Quiet bit to 0.
My Change in Ir_Tcl.cpp:
void IRTcl112Ac::stateReset(void) { // A known good state. (On, Cool, 24C) static const uint8_t reset[kTcl112AcStateLength] = { 0x23, 0xCB, 0x26, 0x01, 0x00, 0x04, 0x03, 0x07, 0x40, 0x00, 0x00, 0x00, 0x00, 0x03}; std::memcpy(_.raw, reset, kTcl112AcStateLength); _quiet = false; _quiet_prev = false; _quiet_explictly_set = false; }