mirror of
https://github.com/espressif/esp-protocols.git
synced 2025-07-23 07:17:29 +02:00
fix(wifi_remote): Added more netif options for eppp connection
Configurable in Kconfig: * routing priority * netif description
This commit is contained in:
@ -30,6 +30,23 @@ endchoice
|
|||||||
help
|
help
|
||||||
Pin number of UART RX.
|
Pin number of UART RX.
|
||||||
|
|
||||||
|
config ESP_WIFI_REMOTE_EPPP_NETIF_PRIORITY
|
||||||
|
int "Routing priority of eppp netif"
|
||||||
|
default 100
|
||||||
|
range 0 256
|
||||||
|
help
|
||||||
|
Set the priority of the wifi-remote netif.
|
||||||
|
The bigger the number the higher the priority.
|
||||||
|
The interface which is up and with the highest priority will act as a default GW.
|
||||||
|
|
||||||
|
config ESP_WIFI_REMOTE_EPPP_NETIF_DESCRIPTION
|
||||||
|
string "eppp network interface description"
|
||||||
|
default "example_netif_sta"
|
||||||
|
help
|
||||||
|
Textual description of the wifi remote network interface.
|
||||||
|
By default it is set to "example_netif_sta" to be used in IDF protocol example
|
||||||
|
as default wifi station substitution.
|
||||||
|
|
||||||
config ESP_WIFI_REMOTE_EPPP_SERVER_CA
|
config ESP_WIFI_REMOTE_EPPP_SERVER_CA
|
||||||
string "Servers CA certificate"
|
string "Servers CA certificate"
|
||||||
default "--- Please copy content of the CA certificate ---"
|
default "--- Please copy content of the CA certificate ---"
|
||||||
|
@ -16,5 +16,7 @@ __attribute__((weak)) esp_netif_t *wifi_remote_eppp_init(eppp_type_t role)
|
|||||||
config.transport = EPPP_TRANSPORT_UART;
|
config.transport = EPPP_TRANSPORT_UART;
|
||||||
config.uart.tx_io = CONFIG_ESP_WIFI_REMOTE_EPPP_UART_TX_PIN;
|
config.uart.tx_io = CONFIG_ESP_WIFI_REMOTE_EPPP_UART_TX_PIN;
|
||||||
config.uart.rx_io = CONFIG_ESP_WIFI_REMOTE_EPPP_UART_RX_PIN;
|
config.uart.rx_io = CONFIG_ESP_WIFI_REMOTE_EPPP_UART_RX_PIN;
|
||||||
|
config.ppp.netif_description = CONFIG_ESP_WIFI_REMOTE_EPPP_NETIF_DESCRIPTION;
|
||||||
|
config.ppp.netif_prio = CONFIG_ESP_WIFI_REMOTE_EPPP_NETIF_PRIORITY;
|
||||||
return eppp_open(role, &config, portMAX_DELAY);
|
return eppp_open(role, &config, portMAX_DELAY);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user