Skip to content

Commit 91d338d

Browse files
committed
revert tinyusb v0.19.0, added the bovaliden register disabling
1 parent f51f91d commit 91d338d

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

device/esp_tinyusb/idf_component.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,5 @@ targets:
1111
dependencies:
1212
idf: '>=5.0' # IDF 4.x contains TinyUSB as submodule
1313
tinyusb:
14-
version: '0.18.0~5'
14+
version: '>=0.17.0~2' # 0.17.0~2 is the first version that supports deinit
1515
public: true

device/esp_tinyusb/tinyusb_task.c

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,15 @@ static void tinyusb_device_task(void *arg)
8282
goto desc_free;
8383
}
8484

85+
#if TUSB_VERSION_NUMBER >= 1900
86+
// Workaround for changing the bvalid override in the tinyusb v0.19.0
87+
if (task_ctx->rhport == TINYUSB_PORT_FULL_SPEED_0) {
88+
USB_DWC_FS.gotgctl_reg.bvalidoven = 0;
89+
} else {
90+
USB_DWC_HS.gotgctl_reg.bvalidoven = 0;
91+
}
92+
#endif // TUSB_VERSION_NUMBER >= 1900
93+
8594
#if (CONFIG_IDF_TARGET_ESP32P4)
8695
if (task_ctx->vbus_monitor_cfg.gpio_num != GPIO_NUM_NC) {
8796
if (tinyusb_vbus_monitor_init(&task_ctx->vbus_monitor_cfg) != ESP_OK) {

0 commit comments

Comments
 (0)