-
-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support toggle climate device #573
Comments
Yes, just rename the pre_heat key to on |
I saw the "on" option, but as I understand, it will called each time send command is called, so when I just change temperature, the on command will be sent and the aircondition will toggle state ...
|
No, there is no way. |
@vassilis-panos The code I've attached ( |
Is there a reason why you need a different pre-code for each mode? |
I assume single pre command (which should turn on the device) is enough but if the pre command sends also the HVAC mode, it will be better to send the correct mode and not to rely on the immediate second command to set the mode correctly. |
I also have this issue — I use a Fujitsu AR-REG1U-controlled heat pump (code 1284 in SmartIR). Once the device is powered off, it cannot be powered on from Home Assistant. However, the Broadlink App can send a power-on command by itself. Perhaps the power-on command could be sent when toggling mode if the state is currently set to off? |
I have the same issue with my Daikin FTN-P. It seems like it needs home assistant to send the power on command (along with the temperature or mode command) only when the state is off, otherwise, send only the temperature or mode. |
@eyalcha your solution worked for me. I know that it is not the case for everyone, but, @vassilis-panos, perhaps it could be implemented as a configurable option?
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Still valid |
Hello, |
I also have a similar issue with my Hisense AC. |
Something like this fixes it for my Hisense AC:
|
Due to incorrect work of SmartIR at the moment I have to realise the same logic via HA script. I appreciate such fixes into the component. |
Yeah I have a similar issue where my air-conditioner has no idempotent on/off button, the state is kept in the unit itself instead. It's a newer model of Daikin anyway. Similar to a TV remote, the power button on the remote will send a "power" signal, and it toggles the air-conditioner on/off based on the previous state (stored in the unit). Inspired by @eyalcha modification above, I made the necessary modification which fits my unit: def __init__(self, hass, config, device_data):
# initialisation of other variables...
# ...
self._previous_hvac_mode = HVACMode.OFF
async def async_set_hvac_mode(self, hvac_mode):
"""Set operation mode."""
self._previous_hvac_mode = self._hvac_mode
self._hvac_mode = hvac_mode
if not hvac_mode == HVACMode.OFF:
self._last_on_operation = hvac_mode
# Pre mode command
# Taken from https://github.com/smartHomeHub/SmartIR/issues/573
# modified to a generic `on_once` for all non-off operation
if hvac_mode != HVACMode.OFF: # don't run if about to turn off
if self._previous_hvac_mode == HVACMode.OFF: # only if it's previously off
if 'on_once' in self._commands:
await self._controller.send(self._commands['on_once'])
await asyncio.sleep(self._delay)
# End pre mode
await self.send_command()
self.async_write_ha_state() Add the attribute "commands": {
"off": "JgCWAAABQwABQgABRAABQ5lRDQsOHQ4dDQwNHQ4LDAwNCwwMDh0NCw0LDgsNHgwMDQsMDA4KDgoNDA0eDR4MDA0LDCALDA0LDQsOCw0dDQwNCwwMDQsOCg0LDh0OCwwMDQsMDA0LDgoNDA0eDQsMDA0eDQsMHwwfDAwOCg4dDQsNDAwfDQsNHgwfDQsNCw0LDgsNAAKcmQANBQ==",
"on_once": "JgCWAAABQwABQgABRAABQ5lRDQsOHQ4dDQwNHQ4LDAwNCwwMDh0NCw0LDgsNHgwMDQsMDA4KDgoNDA0eDR4MDA0LDCALDA0LDQsOCw0dDQwNCwwMDQsOCg0LDh0OCwwMDQsMDA0LDgoNDA0eDQsMDA0eDQsMHwwfDAwOCg4dDQsNDAwfDQsNHgwfDQsNCw0LDgsNAAKcmQANBQ==",
"cool": {
"low": {
"16": "JgCWAAABQwABQgABRQABQZpRDA0LHw0eDA0MHwwMDAwMDAsOCx8NDAsNCw0MDAwMDB8MDAwfDR4MDQsNCw0MHg0MDB4NDAwMDA0LDQsgCwwNDAwMDAwMDAwNCyALDQsNCw0LDQwMDA0LDA0eDA0MDAweDQwMHg4dDQwMHw0MCw0LDQsfDQwMHg0MDAwMDQsfDQwLAAKdmQANBQ==", ** Things to take note: How it behaves: Scenario 1 Scenario 2 Scenario 3
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
The problem has not been solved yet. For example, Panasonic air conditioners work incorrectly because have the same command for both POWER ON and POWER OFF action. |
I also still have this problem
…On Fri, Sep 3, 2021, 5:00 PM Spirituss ***@***.***> wrote:
The problem has not been solved yet. For example, Panasonic air
conditioners work incorrectly because have the same command for both POWER
ON and POWER OFF action.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#573 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AM336IEKHUOFK2KODUSUYTLUACFDNANCNFSM4WXDZCSQ>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
|
So have I ... |
I have the same problem with a pellet stove, which works perfectly with SmartIR except for the latter always sends on command with every mode change. |
Hi, In the meantime this is not added to the official release, is there any way to include the code made by @step-chew in my local installation? |
Hi, if you know how to, you should modify the file climate.py in the custom_compnents/smartir folder of your HA config, adding the lines from @step-chew's reply |
Thanks a lot @matteo-vannucchi. I've seen the file and I think is pretty easy to modify. I'll give it a try. |
I've added the code to my instalation and it works like a charm. It would be very nice to have this in the official release. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Still an issue
…On Sat, Apr 16, 2022, 6:45 PM stale[bot] ***@***.***> wrote:
This issue has been automatically marked as stale because it has not had
recent activity. It will be closed if no further activity occurs. Thank you
for your contributions.
—
Reply to this email directly, view it on GitHub
<#573 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AM336IHMRRA5VWZZTTZJTPTVFKK6JANCNFSM4WXDZCSQ>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Still an issue
…On Sat, Aug 13, 2022, 6:34 PM stale[bot] ***@***.***> wrote:
This issue has been automatically marked as stale because it has not had
recent activity. It will be closed if no further activity occurs. Thank you
for your contributions.
—
Reply to this email directly, view it on GitHub
<#573 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AM336ICE3TOWM346LVWZJKDVY5233ANCNFSM4WXDZCSQ>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
I have this issue too! |
@stephenchew's method isn't working with Daikin. Power on_once & Power off commands work but also give the error:
Other commands don't work at all: temp, fan speed & swing |
Hi! |
Still having this issue. Has this change been merged elsewhere? |
Sorry @madjetey, I didn't upgrade my component, so I didn't know it breaks until recently. I've updated the code (in the original post). It's been tested it on my hass, and I'm using Daikin too 🙂
@pabloromeo, I have a feeling that this will never be merged, and I'm not sure if there's some other workaround. Since this method works perfectly for me, I'm hanging onto this one for now. |
I don't recall which version changed this, but it's been working fine for over a year now for me. The last breaking change I had was the most recent update where I had to manually change line 148 in controller.py to Only issue now is all HVAC commands turn off the air conditioner unit self even when HA says it's on (EG: AC on & adjusting speed turns it off until I apply the speed change again). Same across MQTT & broadlink. Inverse is also true; an AC that is off will turn on if the off command is sent again. |
HI,
Not sure if there is already support /solution for my case, but I didn't find ...
I have an aircondition device which doesn't have sepearte on / off commands. No issue to turn off the device. I have off command in the code file. The issue is with the turn on command. To turn on I actually need to send two commands. First to turn on and then send second command (mode temperature fan). Note that all the temperature commands cannt include the on command because if they wer, each up down temperature will toggle device power state.
The solution that I found was to add a pre mode command and send it each time the mode is changed (mode depended). Is there other option to handle this case without changing teh code? If not, is it possible to add support for that?
Example of command:
The text was updated successfully, but these errors were encountered: