Skip to content
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

Tilting for longer time than in configuration. #5

Closed
pawelma opened this issue Oct 29, 2022 · 4 comments
Closed

Tilting for longer time than in configuration. #5

pawelma opened this issue Oct 29, 2022 · 4 comments

Comments

@pawelma
Copy link
Contributor

pawelma commented Oct 29, 2022

Hello.
Thanks for the great extension.
I just installed it and testing with my blinds, and it works awesome, but there is one caveat with tilting.
My tilt time is around 2100 ms, but from HA it takes around 2800.
So to make it work, I need to select around 70% of the slider to perform the full 180* flip, without opening.
image
When selecting non corner position, my logs show difference between cover start and stop in milliseconds, and it's similar to the config that is set up (around 2100).

Does HA send tilt position to ESP and then ESP loop take over to monitor the tilt, or could that be related with network lag?
Is there any config how to decrease 'loop sleep' interval If ESP is handling the tilt position?

@pawelma
Copy link
Contributor Author

pawelma commented Oct 29, 2022

I guess it might be caused by adding +1 to tilt position % on the time >=

if(current_time - last_tilt_update >= (this->tilt_duration / 100)) {
last_tilt_update = current_time;
relative_tilt=clamp(relative_tilt+1,-100,0);
exact_tilt=clamp(exact_tilt+1,0,100);

Maybe Time based cover approach would work better in that case (If I'll have some time I'll try to refactor) https://github.com/esphome/esphome/blob/e5b8dd7f2d596ff820314b61dee8848b6fe4ea7f/esphome/components/time_based/time_based_cover.cpp#L164.

@DaniEll-AT
Copy link
Contributor

DaniEll-AT commented Dec 28, 2022

Will the test-branch be merged to master?
I am currently using the test-branch because of better precision when tilting. Maybe it's possible modifying it so there is no inverted tilt position (not an issue for me, but for others...)?

Thanks for the great work to all participants 👍

@bruxy70
Copy link
Owner

bruxy70 commented Jan 1, 2023

I think I will leave it for now. There are at least two issues reported with it. So I'd leave the two for the time being. People can use one or the other by changing the ref.
I use them in my house for some time now. It seems to work, but I have noticed that the position does not update whilst the blinds move. Not a big deal, for this kind of blinds I use wither 0 or 100, and control the light by the tilt. But interesting nevertheless.

@DaniEll-AT
Copy link
Contributor

The issue is fixed with #13 👍

@pawelma pawelma closed this as completed Feb 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants