Skip to content

Commit

Permalink
Don't report device heartbeat packets as "unknown"
Browse files Browse the repository at this point in the history
  • Loading branch information
kukulich committed Feb 23, 2021
1 parent 4da006b commit 72803a8
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion custom_components/jablotron100/jablotron.py
Original file line number Diff line number Diff line change
Expand Up @@ -1088,7 +1088,10 @@ def _parse_device_state_packet(self, packet: bytes) -> None:
packet_type_binary = Jablotron._hex_to_bin(packet[2:3])
packet_type = Jablotron.binary_to_int(packet_type_binary[4:])

if (
if packet_type == JABLOTRON_DEVICE_PACKET_TYPE_HEARTBEAT:
# Ignore
pass
elif (
self._is_device_with_activity_sensor(device_number)
and Jablotron._is_device_state_packet_for_activity(packet_type)
):
Expand Down

0 comments on commit 72803a8

Please sign in to comment.