ha-smartthinq-sensors icon indicating copy to clipboard operation
ha-smartthinq-sensors copied to clipboard

Add AC filter remaining time sensor (+ reset switch?)

Open cynicer opened this issue 2 years ago • 6 comments

Is your feature request related to a problem? Please describe. AC filter needs regular cleaning. The AC keeps track of the usage time and has a countdown when to clean the filter.

Describe the solution you'd like Offer a sensor to display the remaining filter hours. After a clean the value can be reset through the LG app, ideally this would also be possible e.g. with a switch.

Describe alternatives you've considered Stopping HA and doing it manually via the LG app.

Additional context I already implemented that on the old plugin, but I'm not really familiar with the the proper HA plugin architecture so I'll just link it here for reference: https://github.com/sampsyo/hass-smartthinq/pull/105

cynicer avatar Aug 17 '22 19:08 cynicer

Add sensors here is not really complicated and filter status was already implemented for other device as Air Purifier, but is not clear how to fetch this information from the AC devices. Please attach diagnostic file or provide some example on how get this information.

ollo69 avatar Aug 17 '22 20:08 ollo69

The filter state is already implemented in wideq (https://github.com/sampsyo/wideq/blob/master/wideq/ac.py#L318). The filter period (the maximum time a filter shall be used) and the used time can be obtained like this: https://github.com/sampsyo/hass-smartthinq/blob/master/sensor.py#L272

It would be nice to have a sensor showing the remaining time in order to build a notification for a filter clean. Additionally it might be useful to publish the filter period in some way as well.

cynicer avatar Aug 18 '22 06:08 cynicer

+1 for this - I'd love to see it working - I'm currently using https://github.com/sampsyo/hass-smartthinq which displays the filter info however I would like to use yours instead

Screen Shot 1

vk2him avatar Aug 19 '22 09:08 vk2him

In any case can you please configure (may be only temporary) the integration and attach here the diagnostic file so that I can check the payload. I need to understand the best way to implement this functionality trying to do this for both V1 and V2 ac type, despite what the old wideq library does.

ollo69 avatar Aug 21 '22 14:08 ollo69

This issue is stale because it has been open 45 days with no activity. Remove stale label or comment or this will be closed in 7 days.

github-actions[bot] avatar Nov 23 '22 02:11 github-actions[bot]

🚀

cynicer avatar Nov 23 '22 06:11 cynicer

I was about to create the exact same request. I have an LG Dualcool and the air filter need to be cleaned after a certain amount of time... The status can be retreived the same way we can retreive the energy consumption if I'm not mistaken.

Taking a look at the other available integration could be a starting point.

SN0WTR00PER avatar Dec 23 '22 05:12 SN0WTR00PER

This feature should be available in last release. Wait for yours feedback.

ollo69 avatar Dec 24 '22 20:12 ollo69

Just updated and reloaded the integration, but I don't have the filter sensor. Shouldn't it just appear in the list?

gabi1324 avatar Dec 25 '22 13:12 gabi1324

Just updated and reloaded the integration, but I don't have the filter sensor. Shouldn't it just appear in the list?

Please attach diagnostics

ollo69 avatar Dec 25 '22 14:12 ollo69

@gabi1324,

what is the current status reported by LG apps for your devices? In the payload all values are = 0, for this reason sensors are not shown (I assume that when max time = 0 the information is not available). May be I should do a specific call to retrieve these data, but in this case we need to investigate....

ollo69 avatar Dec 25 '22 19:12 ollo69

If you are referring to the filter time in the LG app, I have for the living room AC 91% and 649 hours remaining and 71 hours used. I checked the diagnostics also and I don't know why the values are 0.

gabi1324 avatar Dec 25 '22 20:12 gabi1324

I was hoping that information in LG app was not available for you😂. This means that this information must be query with a specific command and is not available in the payload. We must investigate on this. Let's wait for some other feed-back on this thread to see if this is equal for all V2 models or there are different situation.

ollo69 avatar Dec 25 '22 21:12 ollo69

Just updated and reloaded the integration, but I don't have the filter sensor. Shouldn't it just appear in the list?

After updating and reloading, same issue here (LG S12EW). Current filter status is 69% inside the LG Thinq app.

ricoroodenburg avatar Dec 26 '22 08:12 ricoroodenburg

I have 3 ACs in my house connected to LG Thinq. One of them is a ceiling one, and that one is displaying the filter status in my HA instance. The other two, which are wall mounted, are not, even though all 3 does display filter status in the Thinq app.

bellini666 avatar Dec 26 '22 13:12 bellini666

Filter entity and information are present now after updating. Thanks 😊

SN0WTR00PER avatar Jan 02 '23 10:01 SN0WTR00PER

I think that problem here is with device based on ApiV2. They not expose the filter status in pay load and is required a specific command (as for model with ApiV1) but we need to discover the command. Not having a LG climate, there are 2 options:

  • I can try to implement this and release beta version to be tested, if someone is available for testing.
  • If someone is available to share his credential (I will provide an e-mail for this), I will perform test by myself to see if I discover right command.

ollo69 avatar Jan 02 '23 19:01 ollo69

I am willing to test a beta version if you want to do this.

gabi1324 avatar Jan 02 '23 21:01 gabi1324

@ollo69 I can provide you with the credentials to my LG account. Appreciate the work on it!

cynicer avatar Jan 03 '23 05:01 cynicer

@cynicer,

write me an e-mail at --- I need username, password (if you prefer you can set a temporary one) region and language. I promise that I will not play with your device,😉

ollo69 avatar Jan 03 '23 09:01 ollo69

@ollo69 Sent you the credentials, you can remove your address again.

cynicer avatar Jan 03 '23 09:01 cynicer

Thanks, received👍 I'll work on this later today.

ollo69 avatar Jan 03 '23 09:01 ollo69

Thanks for the work on this... I have a wall mounted split system - and the filter doesn't appear on that either.

The only info I can find is:

Device App: 35.94
Modem: clip_hna_v1.9.183_QC
Firmware 1: SAA39723703.00003703.0

The inside unit is a WH24SLN-18 - with ~7KW outdoor unit.

It's been great to see the improvement in this integration :)

Thanks to all involved.

CRCinAU avatar Jan 03 '23 12:01 CRCinAU

@all,

I just released a new version with some fix / test for this feature, please test and let me know.

@cynicer,

for device V1 as yours, filter status now should be available. There was a couple of errors that was preventing status to be displayed. Please note that initial startup could be a little bit longer, because I need to get all available status on first refresh (more device, more time for startup of course). About the reset, I need more time, also because this should be implemented with button platform, still not used in this integration. Let me know if you need to change the account password or if i could still use for future tests.

@gabi1324,

for device V2 I added in this version a new command that should output some logs at info level. Because I don't have a clear idea on how this command should be formatted, let me say that we have 99% of probability that it is not correct and will simply fail. It is inside a controlled exception, so should not create any issue in normal operation. Please install new version, restart HA and share generated log so that I can check result and try again in a new release...

ollo69 avatar Jan 04 '23 00:01 ollo69

Remaining filter life looks good to me after the update. One note though: Is the remaining life in % really the best way to handle this? The total filter life might be different for different devices and could be used in automations if the absolute value was accessible.

Looking forward to the reset button, this is the only use case left I have the ThinQ app installed.

@ollo69 You can continue to use the account, but my ACs are usually disconnected from the power (since they're not active atm). Just let me know via mail when you want to look into something, I'll turn them on.)

cynicer avatar Jan 04 '23 06:01 cynicer

Is this what you need?

Tis is the diagnostics, what I need now is the HomeAssistant log file, possibly the one generated after HomeAssistant reboot (not too big and should contain required info).

ollo69 avatar Jan 04 '23 08:01 ollo69