tiny_usb: rename Kconfig name

1. Renamed Kconfig file of tinyusb (distinguish tinyusb stack from usb
   peripheral)
2. bugfix/typofix/doc update of tinyusb
This commit is contained in:
morris
2021-07-09 11:15:26 +08:00
parent 2218204aa7
commit 81448dcae8
25 changed files with 589 additions and 497 deletions

View File

@@ -1,11 +1,16 @@
idf_build_get_property(target IDF_TARGET)
set(srcs)
set(include)
set(priv_include)
set(priv_require)
#USB Host is currently only supported on ESP32-S2, ESP32S3 chips
if(NOT "${target}" MATCHES "^esp32s[2-3]")
return()
if(CONFIG_USB_OTG_SUPPORTED)
list(APPEND srcs "hcd.c")
list(APPEND priv_include "private_include")
list(APPEND priv_require "hal" "driver")
endif()
idf_component_register(SRCS "hcd.c"
INCLUDE_DIRS ""
PRIV_INCLUDE_DIRS "private_include"
PRIV_REQUIRES hal driver)
idf_component_register(SRCS ${srcs}
INCLUDE_DIRS ${include}
PRIV_INCLUDE_DIRS ${priv_include}
PRIV_REQUIRES ${priv_require}
)

9
components/usb/Kconfig Normal file
View File

@@ -0,0 +1,9 @@
menu "USB-OTG"
visible if IDF_TARGET_ESP32S2 || IDF_TARGET_ESP32S3
# Invisible item, enabled when USB_OTG peripheral does exist
config USB_OTG_SUPPORTED
bool
default y if IDF_TARGET_ESP32S2 || IDF_TARGET_ESP32S3
endmenu