proof of concpet that device pio-usb work with host pio-usb

This commit is contained in:
hathach
2022-04-08 13:36:05 +07:00
parent d97c154695
commit d5d4909c20
6 changed files with 27 additions and 21 deletions

View File

@@ -26,7 +26,7 @@
#include "tusb_option.h"
#if CFG_TUD_ENABLED && CFG_TUSB_MCU == OPT_MCU_RP2040
#if CFG_TUD_ENABLED && (CFG_TUSB_MCU == OPT_MCU_RP2040) && !CFG_TUD_RPI_PIO_USB
#include "pico.h"
#include "rp2040_usb.h"

View File

@@ -239,7 +239,7 @@
#define TUH_OPT_RHPORT -1
#endif
#define CFG_TUH_ENABLED ( TUH_RHPORT_MODE & OPT_MODE_HOST )
#define CFG_TUH_ENABLED (TUH_RHPORT_MODE & OPT_MODE_HOST)
// For backward compatible
#define TUSB_OPT_DEVICE_ENABLED CFG_TUD_ENABLED
@@ -398,6 +398,10 @@
#define CFG_TUH_RPI_PIO_USB 0
#endif
#ifndef CFG_TUD_RPI_PIO_USB
#define CFG_TUD_RPI_PIO_USB 0
#endif
//------------------------------------------------------------------
// Configuration Validation