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

[bug] Polling timer resets on any node report, not targeted value #826

Closed
2 tasks
ghost opened this issue Mar 5, 2021 · 1 comment · Fixed by #827
Closed
2 tasks

[bug] Polling timer resets on any node report, not targeted value #826

ghost opened this issue Mar 5, 2021 · 1 comment · Fixed by #827
Assignees
Labels
bug Something isn't working

Comments

@ghost
Copy link

ghost commented Mar 5, 2021

Version

Build/Run method

  • [ x] Docker
  • PKG
  • Manually built (git clone - npm install - npm run build )

zwavejs2mqtt version: 2.1.0
zwavejs version: 6.6.0

Describe the bug

I have enabled polling in zwave2mqtt with the following configuration.

[134-45-2] Water Sensor (AEON Labs) Battery level (128-0-level) No operation Interval: 3600s

Ideally this means that the command to poll battery level will be queued if no battery report has been received within one hour.

However the device wakes up more than once per hour. The report the node sends to indicate that it is awake or asleep is enough to reset the timer. Any sensor data unrelated to the value being polled will also reset the timer. In order for any polling to occur at all, the polling interval must less than the wakeup interval and the interval of any anticipated sensor data.

2021-03-05 14:04:41.207 INFO ZWAVE: Node 26 is now awake
2021-03-05 14:04:41.211 DEBUG MQTT: Publishing to zwave/BASEMENT/Basement_H2O/status: { time: 1614953081210, value: true, status: 'Awake', nodeId: 26 } with options { qos: 1, retain: true }
2021-03-05 14:04:41.209 DEBUG ZWAVE: 26-128-0-level will be polled in 3600 seconds
2021-03-05 14:04:42.250 INFO ZWAVE: Node 26 is now asleep
2021-03-05 14:04:42.253 DEBUG MQTT: Publishing to zwave/BASEMENT/Basement_H2O/status: { time: 1614953082252, value: true, status: 'Asleep', nodeId: 26 } with options { qos: 1, retain: true 
}
2021-03-05 14:04:42.251 DEBUG ZWAVE: 26-128-0-level will be polled in 3600 seconds

To Reproduce

Poll any battery operated node at an interval greater than it's wakeup interval. Any report received will reset the timer.

Expected behavior

The polling timer should only reset if the report for the polled value i.e. 26-128-0-level has been sent by the node.

Additional context

@ghost ghost added the bug Something isn't working label Mar 5, 2021
@ghost ghost assigned robertsLando Mar 5, 2021
@robertsLando
Copy link
Member

Working on the fix

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant