feat(protocol_examples_common): Add Thread connect to support Thread for the protocol examples

This commit is contained in:
WanqQixiang
2024-11-12 14:39:14 +08:00
parent b70331a9b7
commit c5a9e39653
9 changed files with 354 additions and 10 deletions

View File

@@ -22,6 +22,10 @@ if(CONFIG_EXAMPLE_CONNECT_ETHERNET)
list(APPEND srcs "eth_connect.c")
endif()
if(CONFIG_EXAMPLE_CONNECT_THREAD)
list(APPEND srcs "thread_connect.c")
endif()
if(CONFIG_EXAMPLE_CONNECT_PPP)
list(APPEND srcs "ppp_connect.c")
endif()
@@ -29,7 +33,7 @@ endif()
idf_component_register(SRCS "${srcs}"
INCLUDE_DIRS "include"
PRIV_REQUIRES esp_netif driver esp_wifi vfs console esp_eth)
PRIV_REQUIRES esp_netif driver esp_wifi vfs console esp_eth openthread)
if(CONFIG_EXAMPLE_PROVIDE_WIFI_CONSOLE_CMD)
idf_component_optional_requires(PRIVATE console)
@@ -39,6 +43,10 @@ if(CONFIG_EXAMPLE_CONNECT_ETHERNET)
idf_component_optional_requires(PUBLIC esp_eth)
endif()
if(CONFIG_EXAMPLE_CONNECT_THREAD)
idf_component_optional_requires(PRIVATE openthread)
endif()
if(CONFIG_EXAMPLE_CONNECT_PPP)
idf_component_optional_requires(PRIVATE esp_tinyusb espressif__esp_tinyusb)
endif()