From c2e0d8468d680b754ce651161fc75b52aae79ce6 Mon Sep 17 00:00:00 2001 From: awalol Date: Sat, 16 May 2026 12:51:48 +0800 Subject: [PATCH] fix: state init after connected --- src/bt.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/bt.cpp b/src/bt.cpp index 8f2568b..dac9afc 100644 --- a/src/bt.cpp +++ b/src/bt.cpp @@ -419,7 +419,9 @@ static void l2cap_packet_handler(uint8_t packet_type, uint16_t channel, uint8_t uint8_t report32[142]{}; report32[0] = 0x32; report32[1] = 0x10; // reportSeqCounter - state_set(report32 + 2,sizeof(SetStateData)); + report32[2] = 0x10 | 0 << 6 | 1 << 7; + report32[3] = 0x3f; // 63 bytes + state_set(report32 + 4,sizeof(SetStateData)); bt_write(report32, sizeof(report32)); const auto mtu = l2cap_get_remote_mtu_for_local_cid(hid_interrupt_cid);