Skip to content

Commit

Permalink
feat: extend battery level reading to gcls002
Browse files Browse the repository at this point in the history
feat: extend battery level reading to gcls002
  • Loading branch information
Rickth64 authored Jun 17, 2024
1 parent 84d79b0 commit 49530c5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/xiaomi_ble/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -2000,7 +2000,7 @@ def poll_needed(
# kind of device we are
return False

if self.device_id != 0x0098:
if self.device_id not in [0x03BC, 0x0098]:
return False

return not last_poll or last_poll > TIMEOUT_1DAY
Expand All @@ -2009,7 +2009,7 @@ async def async_poll(self, ble_device: BLEDevice) -> SensorUpdate:
"""
Poll the device to retrieve any values we can't get from passive listening.
"""
if self.device_id == 0x0098:
if self.device_id in [0x03BC, 0x0098]:
client = await establish_connection(
BleakClient, ble_device, ble_device.address
)
Expand Down

0 comments on commit 49530c5

Please sign in to comment.