@@ -316,7 +316,7 @@ static void dfifo_write_packet(uint8_t rhport, uint8_t fifo_num, uint8_t const*
316
316
//--------------------------------------------------------------------
317
317
// Endpoint
318
318
//--------------------------------------------------------------------
319
- #if TU_CHECK_MCU ( OPT_MCU_ESP32S2 , OPT_MCU_ESP32S3 )
319
+ #if defined( TUP_USBIP_DWC2_ESP32 )
320
320
// Keep count of how many FIFOs are in use
321
321
static uint8_t _allocated_fifos = 1 ; //FIFO0 is always in use
322
322
@@ -344,7 +344,7 @@ static void edpt_activate(uint8_t rhport, tusb_desc_endpoint_t const * p_endpoin
344
344
if (dir == TUSB_DIR_IN ) {
345
345
//epctl |= (epnum << DIEPCTL_TXFNUM_Pos);
346
346
uint8_t fifo_num = epnum ;
347
- #if TU_CHECK_MCU ( OPT_MCU_ESP32S2 , OPT_MCU_ESP32S3 )
347
+ #if defined( TUP_USBIP_DWC2_ESP32 )
348
348
// Special Case for EP5, which is used by CDC but not actually called by the driver
349
349
// we can give it a fake FIFO
350
350
if (epnum == 5 ) {
@@ -866,7 +866,7 @@ void dcd_edpt_close_all(uint8_t rhport) {
866
866
}
867
867
}
868
868
869
- #if TU_CHECK_MCU ( OPT_MCU_ESP32S2 , OPT_MCU_ESP32S3 )
869
+ #if defined( TUP_USBIP_DWC2_ESP32 )
870
870
_allocated_fifos = 1 ;
871
871
#endif
872
872
@@ -1216,7 +1216,7 @@ void dcd_int_handler(uint8_t rhport) {
1216
1216
if (int_status & GINTSTS_USBRST ) {
1217
1217
// USBRST is start of reset.
1218
1218
dwc2 -> gintsts = GINTSTS_USBRST ;
1219
- #if TU_CHECK_MCU ( OPT_MCU_ESP32S2 , OPT_MCU_ESP32S3 )
1219
+ #if defined( TUP_USBIP_DWC2_ESP32 )
1220
1220
_allocated_fifos = 1 ;
1221
1221
#endif
1222
1222
bus_reset (rhport );
@@ -1252,7 +1252,7 @@ void dcd_int_handler(uint8_t rhport) {
1252
1252
dwc2 -> gintsts = GINTSTS_USBSUSP ;
1253
1253
//dcd_event_bus_signal(rhport, DCD_EVENT_SUSPEND, true);
1254
1254
dcd_event_bus_signal (rhport , DCD_EVENT_UNPLUGGED , true);
1255
- #if TU_CHECK_MCU ( OPT_MCU_ESP32S2 , OPT_MCU_ESP32S3 )
1255
+ #if defined( TUP_USBIP_DWC2_ESP32 )
1256
1256
_allocated_fifos = 1 ;
1257
1257
#endif
1258
1258
}
@@ -1271,7 +1271,7 @@ void dcd_int_handler(uint8_t rhport) {
1271
1271
1272
1272
if (otg_int & GOTGINT_SEDET ) {
1273
1273
dcd_event_bus_signal (rhport , DCD_EVENT_UNPLUGGED , true);
1274
- #if TU_CHECK_MCU ( OPT_MCU_ESP32S2 , OPT_MCU_ESP32S3 )
1274
+ #if defined( TUP_USBIP_DWC2_ESP32 )
1275
1275
_allocated_fifos = 1 ;
1276
1276
#endif
1277
1277
}
0 commit comments