File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed
plugwise_usb/nodes/helpers Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -267,16 +267,28 @@ def update_pulse_counter(
267267 if not (self ._rollover_consumption or self ._rollover_production ):
268268 # No rollover based on time, check rollover based on counter reset
269269 # Required for special cases like nodes which have been power off for several days
270+ _LOGGER .debug (
271+ "_rollover_consumption | self._pulses_consumption=%s | pulses_consumed=%s" ,
272+ self ._pulses_production ,
273+ pulses_produced ,
274+ )
270275 if (
271276 self ._pulses_consumption is not None
272277 and self ._pulses_consumption > pulses_consumed
273278 ):
274279 self ._rollover_consumption = True
280+
281+ _LOGGER .debug (
282+ "_rollover_production | self._pulses_production=%s | pulses_produced=%s" ,
283+ self ._pulses_production ,
284+ pulses_produced ,
285+ )
275286 if (
276287 self ._pulses_production is not None
277288 and self ._pulses_production < pulses_produced
278289 ):
279290 self ._rollover_production = True
291+
280292 self ._pulses_consumption = pulses_consumed
281293 self ._pulses_production = pulses_produced
282294
You can’t perform that action at this time.
0 commit comments