fix: DSE Profile Save. Thanks @fuhuasxflwb

This commit is contained in:
awalol
2026-05-05 21:14:29 +08:00
parent 826c3eef9c
commit 7358a81d11
2 changed files with 13 additions and 2 deletions
+8 -1
View File
@@ -480,7 +480,14 @@ vector<uint8_t> get_feature_data(uint8_t reportId, uint16_t len) {
if (feature_data.contains(reportId)) {
ret = feature_data[reportId];
}
if (!feature_data.contains(reportId) || reportId == 0x81) {
if (!feature_data.contains(reportId) ||
// Get Test Command Result
reportId == 0x81 ||
// DSE: Set Profile Save?
reportId == 0x63 ||
reportId == 0x65 ||
reportId == 0x64
) {
if (hid_control_cid != 0) {
uint8_t get_feature[] = {0x43, reportId};
l2cap_send(hid_control_cid, get_feature, sizeof(get_feature));
+5 -1
View File
@@ -154,7 +154,11 @@ void tud_hid_set_report_cb(uint8_t itf, uint8_t report_id, hid_report_type_t rep
}
}
}
if (report_id == 0x80) {
if (report_id == 0x80 ||
// DSE: Write Profile Block
report_id == 0x60 ||
report_id == 0x62 ||
report_id == 0x61) {
set_feature_data(report_id,const_cast<uint8_t *>(buffer),bufsize);
return;
}