openthread: integrate OpenThread network interface with esp_netif

This commit is contained in:
Jiacheng Guo
2021-05-19 11:52:51 +08:00
parent 71be904cf1
commit 52a68cb7fe
22 changed files with 888 additions and 475 deletions

View File

@@ -537,6 +537,12 @@ static const esp_err_msg_t esp_err_msg_table[] = {
# endif
# ifdef ESP_ERR_ESP_NETIF_DNS_NOT_CONFIGURED
ERR_TBL_IT(ESP_ERR_ESP_NETIF_DNS_NOT_CONFIGURED), /* 20490 0x500a */
# endif
# ifdef ESP_ERR_ESP_NETIF_MLD6_FAILED
ERR_TBL_IT(ESP_ERR_ESP_NETIF_MLD6_FAILED), /* 20490 0x500b */
# endif
# ifdef ESP_ERR_ESP_NETIF_IP6_ADDR_FAILED
ERR_TBL_IT(ESP_ERR_ESP_NETIF_IP6_ADDR_FAILED), /* 20490 0x500a */
# endif
// components/esp_common/include/esp_err.h
# ifdef ESP_ERR_FLASH_BASE
@@ -759,7 +765,7 @@ const char *esp_err_to_name(esp_err_t code)
#ifdef CONFIG_ESP_ERR_TO_NAME_LOOKUP
size_t i;
for (i = 0; i < sizeof(esp_err_msg_table)/sizeof(esp_err_msg_table[0]); ++i) {
for (i = 0; i < sizeof(esp_err_msg_table) / sizeof(esp_err_msg_table[0]); ++i) {
if (esp_err_msg_table[i].code == code) {
return esp_err_msg_table[i].msg;
}
@@ -774,7 +780,7 @@ const char *esp_err_to_name_r(esp_err_t code, char *buf, size_t buflen)
#ifdef CONFIG_ESP_ERR_TO_NAME_LOOKUP
size_t i;
for (i = 0; i < sizeof(esp_err_msg_table)/sizeof(esp_err_msg_table[0]); ++i) {
for (i = 0; i < sizeof(esp_err_msg_table) / sizeof(esp_err_msg_table[0]); ++i) {
if (esp_err_msg_table[i].code == code) {
strlcpy(buf, esp_err_msg_table[i].msg, buflen);
return buf;