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

Implement optional update coordinator to call refreshState periodically #167

Open
iMicknl opened this issue Jul 24, 2020 · 4 comments
Open
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@iMicknl
Copy link
Owner

iMicknl commented Jul 24, 2020

Is your feature request related to a problem? Please describe.
When we move towards using an event based approach for updating states (#1), it would be good to understand if we need to refresh the states manually for specific devices, or if we can do it in batch.

For example;

Describe the solution you'd like
Getting rid of manually calling all refresh endpoints would be best, or scheduling a refresh of all states periodically.

Describe alternatives you've considered
Maintaining a list of states that have to be refreshed manually.

@iMicknl iMicknl added the enhancement New feature or request label Jul 24, 2020
@iMicknl
Copy link
Owner Author

iMicknl commented Jul 27, 2020

Just found a reference to stateRefreshCommand in https://www.tahomalink.com/enduser-mobile-web/steer-html5-client/vendor/somfy/io/alarm/alarm.js. Is worthwhile to investigate.

stateRefreshCommand: {commands: "refreshState", label: i18n.refreshState},

@iMicknl
Copy link
Owner Author

iMicknl commented Aug 28, 2020

https://github.com/dubocr/homebridge-tahoma/blob/984a8e440e081a3f34960a0303bcbda245f60de6/overkiz-api.js#L407

The HomeKit (via homebridge) integration is also calling this endpoint every x minutes (based on user setting). We could add this as well, next to our regular data update coordinator.

@iMicknl iMicknl changed the title Investigate use of refresh methods for specific states Implement update coordinator to refresh methods for specific states Sep 2, 2020
@iMicknl iMicknl changed the title Implement update coordinator to refresh methods for specific states Implement optional update coordinator to call refreshState periodically Sep 2, 2020
@iMicknl iMicknl added this to the core release milestone Sep 17, 2020
@tetienne
Copy link
Collaborator

What about doing this automatically if we detect a device required it ?

@iMicknl
Copy link
Owner Author

iMicknl commented Jul 21, 2021

What about doing this automatically if we detect a device required it ?

I had the same thought this morning, would make a lot of sense. Just enable this for the devices where we require it and don't make it user configurable.

@iMicknl iMicknl removed this from the core release milestone Aug 11, 2021
fetzerch added a commit to fetzerch/homeassistant-core that referenced this issue Sep 2, 2023
The Somfy Dexxo smart io (io:DiscreteGarageOpenerWithPartialPositionIOComponent)
supports a third position state: partial. This state is meant to be
used to ventilate the garage.

This commit adds a select entity for the position state. The
implementation is very similar to the already existing position state
for gate's with a pedestrian position.

Note: For the updates to work properly, we'd still need
iMicknl/ha-tahoma#167 /
iMicknl/ha-tahoma#271 to be implemented.
See Somfy-Developer/Somfy-TaHoma-Developer-Mode#26
for discussion with Somfy.
fetzerch added a commit to fetzerch/homeassistant-core that referenced this issue Sep 2, 2023
Somfy gates & garage doors will not automatically send state updates.
They have to be explicitly requested. The TaHoma app/web interface
therefore asks all devices to send their state updates on start.

This change adds a new OverkizDeviceRefreshCoordinator for impacted
devices and will periodically (5min) ask the specific device to send
state updates.

Note that even though these devices typically also provide commands
such as refreshPedestrianPosition/refreshPartialPosition but they do
not cause the device to send its actual state to the gateway.

See Somfy-Developer/Somfy-TaHoma-Developer-Mode#26
and iMicknl/ha-tahoma#167.
fetzerch added a commit to fetzerch/homeassistant-core that referenced this issue Sep 2, 2023
Somfy gates & garage doors will not automatically send state updates.
They have to be explicitly requested. The TaHoma app/web interface
therefore asks all devices to send their state updates on start.

This change adds a new OverkizDeviceRefreshCoordinator for impacted
devices and will periodically (5min) ask the specific device to send
state updates.

Note that even though these devices typically also provide commands
such as refreshPedestrianPosition/refreshPartialPosition but they do
not cause the device to send its actual state to the gateway.

See Somfy-Developer/Somfy-TaHoma-Developer-Mode#26
and iMicknl/ha-tahoma#167.
fetzerch added a commit to fetzerch/homeassistant-core that referenced this issue Sep 2, 2023
The Somfy Dexxo smart io (io:DiscreteGarageOpenerWithPartialPositionIOComponent)
supports a third position state: partial. This state is meant to be
used to ventilate the garage.

This commit adds a select entity for the position state. The
implementation is very similar to the already existing position state
for gate's with a pedestrian position.

Note: For the updates to work properly, we'd still need
iMicknl/ha-tahoma#167 /
iMicknl/ha-tahoma#271 to be implemented.
See Somfy-Developer/Somfy-TaHoma-Developer-Mode#26
for discussion with Somfy.
fetzerch added a commit to fetzerch/homeassistant-core that referenced this issue Sep 4, 2023
The Somfy Dexxo smart io (io:DiscreteGarageOpenerWithPartialPositionIOComponent)
supports a third position state: partial. This state is meant to be
used to ventilate the garage.

This commit adds a select entity for the position state. The
implementation is very similar to the already existing position state
for gate's with a pedestrian position.

Note: For the updates to work properly, we'd still need
iMicknl/ha-tahoma#167 /
iMicknl/ha-tahoma#271 to be implemented.
See Somfy-Developer/Somfy-TaHoma-Developer-Mode#26
for discussion with Somfy.
fetzerch added a commit to fetzerch/homeassistant-core that referenced this issue Sep 4, 2023
Somfy gates & garage doors will not automatically send state updates.
They have to be explicitly requested. The TaHoma app/web interface
therefore asks all devices to send their state updates on start.

This change adds a new OverkizDeviceRefreshCoordinator for impacted
devices and will periodically (5min) ask the specific device to send
state updates.

Note that even though these devices typically also provide commands
such as refreshPedestrianPosition/refreshPartialPosition but they do
not cause the device to send its actual state to the gateway.

See Somfy-Developer/Somfy-TaHoma-Developer-Mode#26
and iMicknl/ha-tahoma#167.
fetzerch added a commit to fetzerch/homeassistant-core that referenced this issue Sep 4, 2023
The Somfy Dexxo smart io (io:DiscreteGarageOpenerWithPartialPositionIOComponent)
supports a third position state: partial. This state is meant to be
used to ventilate the garage.

This commit adds a select entity for the position state. The
implementation is very similar to the already existing position state
for gate's with a pedestrian position.

Note: For the updates to work properly, we'd still need
iMicknl/ha-tahoma#167 /
iMicknl/ha-tahoma#271 to be implemented.
See Somfy-Developer/Somfy-TaHoma-Developer-Mode#26
for discussion with Somfy.
fetzerch added a commit to fetzerch/homeassistant-core that referenced this issue Sep 4, 2023
Somfy gates & garage doors will not automatically send state updates.
They have to be explicitly requested. The TaHoma app/web interface
therefore asks all devices to send their state updates on start.

This change adds a new OverkizDeviceRefreshCoordinator for impacted
devices and will periodically (5min) ask the specific device to send
state updates.

Note that even though these devices typically also provide commands
such as refreshPedestrianPosition/refreshPartialPosition but they do
not cause the device to send its actual state to the gateway.

See Somfy-Developer/Somfy-TaHoma-Developer-Mode#26
and iMicknl/ha-tahoma#167.
fetzerch added a commit to fetzerch/homeassistant-core that referenced this issue Sep 11, 2023
The Somfy Dexxo smart io (io:DiscreteGarageOpenerWithPartialPositionIOComponent)
supports a third position state: partial. This state is meant to be
used to ventilate the garage.

This commit adds a select entity for the position state. The
implementation is very similar to the already existing position state
for gate's with a pedestrian position.

Note: For the updates to work properly, we'd still need
iMicknl/ha-tahoma#167 /
iMicknl/ha-tahoma#271 to be implemented.
See Somfy-Developer/Somfy-TaHoma-Developer-Mode#26
for discussion with Somfy.
fetzerch added a commit to fetzerch/homeassistant-core that referenced this issue Sep 28, 2023
The Somfy Dexxo smart io (io:DiscreteGarageOpenerWithPartialPositionIOComponent)
supports a third position state: partial. This state is meant to be
used to ventilate the garage.

This commit adds a select entity for the position state. The
implementation is very similar to the already existing position state
for gate's with a pedestrian position.

Note: For the updates to work properly, we'd still need
iMicknl/ha-tahoma#167 /
iMicknl/ha-tahoma#271 to be implemented.
See Somfy-Developer/Somfy-TaHoma-Developer-Mode#26
for discussion with Somfy.
fetzerch added a commit to fetzerch/homeassistant-core that referenced this issue Sep 28, 2023
The Somfy Dexxo smart io (io:DiscreteGarageOpenerWithPartialPositionIOComponent)
supports a third position state: partial. This state is meant to be
used to ventilate the garage.

This commit adds a select entity for the position state. The
implementation is very similar to the already existing position state
for gate's with a pedestrian position.

Note: For the updates to work properly, we'd still need
iMicknl/ha-tahoma#167 /
iMicknl/ha-tahoma#271 to be implemented.
See Somfy-Developer/Somfy-TaHoma-Developer-Mode#26
for discussion with Somfy.
iMicknl pushed a commit to fetzerch/homeassistant-core that referenced this issue Oct 10, 2023
The Somfy Dexxo smart io (io:DiscreteGarageOpenerWithPartialPositionIOComponent)
supports a third position state: partial. This state is meant to be
used to ventilate the garage.

This commit adds a select entity for the position state. The
implementation is very similar to the already existing position state
for gate's with a pedestrian position.

Note: For the updates to work properly, we'd still need
iMicknl/ha-tahoma#167 /
iMicknl/ha-tahoma#271 to be implemented.
See Somfy-Developer/Somfy-TaHoma-Developer-Mode#26
for discussion with Somfy.
iMicknl pushed a commit to fetzerch/homeassistant-core that referenced this issue Nov 7, 2023
The Somfy Dexxo smart io (io:DiscreteGarageOpenerWithPartialPositionIOComponent)
supports a third position state: partial. This state is meant to be
used to ventilate the garage.

This commit adds a select entity for the position state. The
implementation is very similar to the already existing position state
for gate's with a pedestrian position.

Note: For the updates to work properly, we'd still need
iMicknl/ha-tahoma#167 /
iMicknl/ha-tahoma#271 to be implemented.
See Somfy-Developer/Somfy-TaHoma-Developer-Mode#26
for discussion with Somfy.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
2 participants