From 97f9f248f4ca09ab8b2bbb3806d9c23ccc038224 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timo=20Kr=C3=B6ger?= Date: Mon, 26 Dec 2022 09:35:23 +0100 Subject: [PATCH 1/2] usb cdc-acm: Remove unused call management descriptor --- embassy-usb/src/class/cdc_acm.rs | 9 --------- 1 file changed, 9 deletions(-) diff --git a/embassy-usb/src/class/cdc_acm.rs b/embassy-usb/src/class/cdc_acm.rs index 09bb1cc8..7f66c5d5 100644 --- a/embassy-usb/src/class/cdc_acm.rs +++ b/embassy-usb/src/class/cdc_acm.rs @@ -18,7 +18,6 @@ const CDC_PROTOCOL_NONE: u8 = 0x00; const CS_INTERFACE: u8 = 0x24; const CDC_TYPE_HEADER: u8 = 0x00; -const CDC_TYPE_CALL_MANAGEMENT: u8 = 0x01; const CDC_TYPE_ACM: u8 = 0x02; const CDC_TYPE_UNION: u8 = 0x06; @@ -197,14 +196,6 @@ impl<'d, D: Driver<'d>> CdcAcmClass<'d, D> { data_if.into(), // bSubordinateInterface ], ); - alt.descriptor( - CS_INTERFACE, - &[ - CDC_TYPE_CALL_MANAGEMENT, // bDescriptorSubtype - 0x00, // bmCapabilities - data_if.into(), // bDataInterface - ], - ); let comm_ep = alt.endpoint_interrupt_in(8, 255); From 4e0d563997017492aa46025e8809653c14e0f875 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timo=20Kr=C3=B6ger?= Date: Mon, 26 Dec 2022 09:36:04 +0100 Subject: [PATCH 2/2] usb cdc-acm: Set flag for supported capabilities --- embassy-usb/src/class/cdc_acm.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/embassy-usb/src/class/cdc_acm.rs b/embassy-usb/src/class/cdc_acm.rs index 7f66c5d5..84db2062 100644 --- a/embassy-usb/src/class/cdc_acm.rs +++ b/embassy-usb/src/class/cdc_acm.rs @@ -185,7 +185,10 @@ impl<'d, D: Driver<'d>> CdcAcmClass<'d, D> { CS_INTERFACE, &[ CDC_TYPE_ACM, // bDescriptorSubtype - 0x00, // bmCapabilities + 0x02, // bmCapabilities: + // D1: Device supports the request combination of + // Set_Line_Coding, Set_Control_Line_State, Get_Line_Coding, + // and the Notification Serial_State. ], ); alt.descriptor(