1 /* 2 * SPDX-FileCopyrightText: 2015-2021 Espressif Systems (Shanghai) CO LTD 3 * 4 * SPDX-License-Identifier: Apache-2.0 5 */ 6 7 #include "esp_netif.h" 8 #include "esp_wifi_default.h" 9 #if CONFIG_ETH_ENABLED 10 #include "esp_eth.h" 11 #endif 12 13 // 14 // Purpose of this module is to provide 15 // - general esp-netif definitions of default objects for STA, AP, ETH 16 // - default init / create functions for basic default interfaces 17 // 18 19 20 21 // 22 // Default configuration of common interfaces, such as STA, AP, ETH 23 // 24 const esp_netif_inherent_config_t _g_esp_netif_inherent_sta_config = ESP_NETIF_INHERENT_DEFAULT_WIFI_STA(); 25 26 #ifdef CONFIG_ESP_WIFI_SOFTAP_SUPPORT 27 const esp_netif_inherent_config_t _g_esp_netif_inherent_ap_config = ESP_NETIF_INHERENT_DEFAULT_WIFI_AP(); 28 #endif 29 30 const esp_netif_inherent_config_t _g_esp_netif_inherent_eth_config = ESP_NETIF_INHERENT_DEFAULT_ETH(); 31 32 const esp_netif_inherent_config_t _g_esp_netif_inherent_ppp_config = ESP_NETIF_INHERENT_DEFAULT_PPP(); 33 34 const esp_netif_inherent_config_t _g_esp_netif_inherent_slip_config = ESP_NETIF_INHERENT_DEFAULT_SLIP(); 35 36 const esp_netif_inherent_config_t _g_esp_netif_inherent_openthread_config = ESP_NETIF_INHERENT_DEFAULT_OPENTHREAD(); 37 38 const esp_netif_ip_info_t _g_esp_netif_soft_ap_ip = { 39 .ip = { .addr = ESP_IP4TOADDR( 192, 168, 4, 1) }, 40 .gw = { .addr = ESP_IP4TOADDR( 192, 168, 4, 1) }, 41 .netmask = { .addr = ESP_IP4TOADDR( 255, 255, 255, 0) }, 42 }; 43