diff options
author | Devaev Maxim <[email protected]> | 2020-12-24 15:49:23 +0300 |
---|---|---|
committer | Devaev Maxim <[email protected]> | 2020-12-24 15:49:23 +0300 |
commit | edb967c633487c90846a6df69adb3842a91fd95c (patch) | |
tree | bca84753053372e66fff092ad1af24fc8da38a71 /kvmd/plugins/hid/_mcu/proto.py | |
parent | 4b6d7605c515adb6b14875f48e7066b1ddcc8948 (diff) |
hid set_connected api
Diffstat (limited to 'kvmd/plugins/hid/_mcu/proto.py')
-rw-r--r-- | kvmd/plugins/hid/_mcu/proto.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/kvmd/plugins/hid/_mcu/proto.py b/kvmd/plugins/hid/_mcu/proto.py index 7cfc3fd7..a0f83528 100644 --- a/kvmd/plugins/hid/_mcu/proto.py +++ b/kvmd/plugins/hid/_mcu/proto.py @@ -83,6 +83,15 @@ class SetMouseOutputEvent(BaseEvent): # ===== [email protected](frozen=True) +class SetConnectedEvent(BaseEvent): + connected: bool + + def make_request(self) -> bytes: + return _make_request(struct.pack(">BBxxx", 0x05, int(self.connected))) + + +# ===== class ClearEvent(BaseEvent): def make_request(self) -> bytes: return _make_request(b"\x10\x00\x00\x00\x00") |