Add detach/attach re-enumeration after MIDI interface added

This commit is contained in:
2026-06-24 00:20:45 +00:00
parent 5fdf45aa14
commit 9ebd568b9c
+7
View File
@@ -18,6 +18,13 @@ bool UsbMidiTransport::begin() {
return false;
}
if (TinyUSBDevice.mounted()) {
Serial.println("[MIDI] Re-enumerating with MIDI interface...");
TinyUSBDevice.detach();
delay(10);
TinyUSBDevice.attach();
}
initialized = true;
return true;
}