mirror of
https://github.com/mjg59/python-broadlink.git
synced 2024-11-10 18:00:12 +01:00
Add method for changing device name (#381)
This commit is contained in:
parent
ca8a5c6a8b
commit
76bcfd0bfb
@ -235,6 +235,12 @@ class device:
|
||||
|
||||
return True
|
||||
|
||||
def change_name(self, name):
|
||||
packet = bytearray(4)
|
||||
packet.extend(map(ord, name))
|
||||
response = self.send_packet(0x6a, packet)
|
||||
check_error(response[0x22:0x24])
|
||||
|
||||
def get_type(self):
|
||||
return self.type
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user