Skip to content

Commit d10dd23

Browse files
committed
split console interface into separate IAD
Otherwise Windows doesn't recognize it Signed-off-by: Daniel Schaefer <dhs@frame.work>
1 parent b8b0aca commit d10dd23

File tree

2 files changed

+14
-1
lines changed

2 files changed

+14
-1
lines changed

tmk_core/protocol/usb_descriptor.c

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -645,7 +645,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = {
645645
.Type = DTYPE_InterfaceAssociation
646646
},
647647
.FirstInterfaceIndex = KEYBOARD_INTERFACE,
648-
.TotalInterfaces = RP2040_RESET_INTERFACE, // It's the interface after this
648+
.TotalInterfaces = CONSOLE_INTERFACE, // It's the interface after this
649649
.Class = HID_CSCP_HIDClass,
650650
.SubClass = 0x00, // HID_CSCP_BootSubclass,
651651
.Protocol = 0x00, // HID_CSCP_KeyboardBootProtocol,
@@ -826,6 +826,18 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = {
826826
},
827827
#endif
828828

829+
.Console_Interface_Association = {
830+
.Header = {
831+
.Size = sizeof(USB_Descriptor_Interface_Association_t),
832+
.Type = DTYPE_InterfaceAssociation
833+
},
834+
.FirstInterfaceIndex = CONSOLE_INTERFACE,
835+
.TotalInterfaces = 1,
836+
.Class = HID_CSCP_HIDClass,
837+
.SubClass = 0x00,
838+
.Protocol = 0x00,
839+
.IADStrIndex = NO_DESCRIPTOR,
840+
},
829841
#ifdef CONSOLE_ENABLE
830842
/*
831843
* Console

tmk_core/protocol/usb_descriptor.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,7 @@ typedef struct {
9393
USB_Descriptor_Endpoint_t Shared_INEndpoint;
9494
#endif
9595

96+
USB_Descriptor_Interface_Association_t Console_Interface_Association;
9697
#ifdef CONSOLE_ENABLE
9798
// Console HID Interface
9899
USB_Descriptor_Interface_t Console_Interface;

0 commit comments

Comments
 (0)