Skip to content

Commit 37bda44

Browse files
Merge pull request #295 from espressif/fix/tinyusb_0.19_compatibility
fix(esp_tinyusb): Fix compatibility with tinyusb 0.19
2 parents 82b707c + 188baa1 commit 37bda44

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

device/esp_tinyusb/tinyusb_task.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@
1414
#include "sdkconfig.h"
1515
#include "descriptors_control.h"
1616

17-
#ifndef tusb_deinit
17+
#if TUSB_VERSION_NUMBER < 1900 // < 0.19.0
1818
#define tusb_deinit(x) tusb_teardown(x) // For compatibility with tinyusb component versions from 0.17.0~2 to 0.18.0~5
19-
#endif // tusb_deinit
19+
#endif
2020

2121
const static char *TAG = "tinyusb_task";
2222

host/usb/test/target_test/enum/main/mock_dev.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@
2828
#define USB_SRP_BVALID_IN_IDX USB_SRP_BVALID_PAD_IN_IDX
2929
#endif // CONFIG_IDF_TARGET_ESP32P4
3030

31-
#ifndef tusb_deinit
32-
#define tusb_deinit(x) tusb_teardown(x) // For compatibility with older tinyusb component versions
33-
#endif // tusb_deinit
31+
#if TUSB_VERSION_NUMBER < 1900 // < 0.19.0
32+
#define tusb_deinit(x) tusb_teardown(x) // For compatibility with tinyusb component versions from 0.17.0~2 to 0.18.0~5
33+
#endif
3434

3535
//
3636
// Test configuration

0 commit comments

Comments
 (0)