We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7f8a0ba commit 029330dCopy full SHA for 029330d
cores/esp32/esp32-hal-tinyusb.c
@@ -62,6 +62,10 @@ typedef struct {
62
bool external_phy;
63
} tinyusb_config_t;
64
65
+#if __has_include("hal/usb_hal.h")
66
+
67
+#include "hal/usb_hal.h"
68
69
static bool usb_otg_deinit(void *busptr) {
70
// Once USB OTG is initialized, its GPIOs are assigned and it shall never be deinited
71
// except when S3 swithicng usb from cdc to jtag while resetting to bootrom
@@ -72,10 +76,6 @@ static bool usb_otg_deinit(void *busptr) {
72
76
#endif
73
77
}
74
78
75
-#if __has_include("hal/usb_hal.h")
-
-#include "hal/usb_hal.h"
79
static void configure_pins(usb_hal_context_t *usb) {
80
for (const usb_iopin_dsc_t *iopin = usb_periph_iopins; iopin->pin != -1; ++iopin) {
81
if ((usb->use_external_phy) || (iopin->ext_phy_only == 0)) {
0 commit comments