Skip to content

Commit

Permalink
yeelight: add dump_ble_debug (#1053)
Browse files Browse the repository at this point in the history
  • Loading branch information
rytilahti authored Jun 4, 2021
1 parent 14652f6 commit c8ed97b
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions miio/yeelight.py
Original file line number Diff line number Diff line change
Expand Up @@ -404,6 +404,21 @@ def set_default(self):
"""Set current state as default."""
return self.send("set_default")

@command(click.argument("table", default="evtRuleTbl"))
def dump_ble_debug(self, table):
"""Dump the BLE debug table, defaults to evtRuleTbl.
Some Yeelight devices offer support for BLE remotes.
This command allows dumping the information about paired remotes,
that can be used to decrypt the beacon payloads from these devices.
Example:
[{'mac': 'xxx', 'evtid': 4097, 'pid': 950, 'beaconkey': 'xxx'},
{'mac': 'xxx', 'evtid': 4097, 'pid': 339, 'beaconkey': 'xxx'}]
"""
return self.send("ble_dbg_tbl_dump", {"table": table})

def set_scene(self, scene, *vals):
"""Set the scene."""
raise NotImplementedError("Setting the scene is not implemented yet.")
Expand Down

0 comments on commit c8ed97b

Please sign in to comment.