1# Copyright (c) 2019 Tobias Svehagen 2# SPDX-License-Identifier: Apache-2.0 3 4menuconfig WIFI_ESP_AT 5 bool "Espressif AT Command support" 6 select MODEM 7 select MODEM_CONTEXT 8 select MODEM_CMD_HANDLER 9 select MODEM_IFACE_UART 10 select NET_L2_WIFI_MGMT 11 select WIFI_OFFLOAD 12 help 13 Enable Espressif AT Command offloaded WiFi driver. It is supported on 14 any serial capable platform and communicates with Espressif chips 15 running ESP-AT firmware (https://github.com/espressif/esp-at). 16 17if WIFI_ESP_AT 18 19config WIFI_ESP_AT_RX_STACK_SIZE 20 int "Stack size for the Espressif esp wifi driver RX thread" 21 default 1024 22 help 23 This stack is used by the Espressif ESP RX thread. 24 25config WIFI_ESP_AT_RX_THREAD_PRIORITY 26 int "Priority of RX thread" 27 default 7 28 help 29 Priority of thread used for processing RX data. 30 31config WIFI_ESP_AT_WORKQ_STACK_SIZE 32 int "Stack size for the esp driver work queue" 33 default 2048 34 help 35 This stack is used by the work queue to pass off net_pkt data 36 to the rest of the network stack, letting the rx thread continue 37 processing data. 38 39config WIFI_ESP_AT_WORKQ_THREAD_PRIORITY 40 int "Priority of work queue thread" 41 default 7 42 help 43 Priority of thread used for processing driver work queue items. 44 45config WIFI_ESP_AT_MDM_RING_BUF_SIZE 46 int "Modem ring buffer size" 47 default 1024 48 help 49 Ring buffer size used by modem UART interface handler. 50 51config WIFI_ESP_AT_MDM_RX_BUF_COUNT 52 int "Modem RX buffer count" 53 default 30 54 help 55 Number of preallocated RX buffers used by modem command handler. 56 57config WIFI_ESP_AT_MDM_RX_BUF_SIZE 58 int "Modem RX buffer size" 59 default 128 60 help 61 Size of preallocated RX buffers used by modem command handler. 62 63config WIFI_ESP_AT_PASSIVE_MODE 64 bool "Use passive mode" 65 help 66 This lets the ESP handle the TCP window so that data can flow 67 at a rate that the driver can handle. Without this, data might get 68 lost if the driver cannot empty the device buffer quickly enough. 69 70config WIFI_ESP_AT_RESET_TIMEOUT 71 int "Reset timeout" 72 default 3000 73 help 74 How long to wait for device to become ready after AT+RST has been 75 sent. This can vary with chipset (ESP8266/ESP32) and firmware 76 version. This is ignored if a reset pin is configured. 77 78config WIFI_ESP_AT_RX_NET_PKT_ALLOC_TIMEOUT 79 int "Network interface RX packet allocation timeout" 80 default 5000 81 help 82 Network interface RX net_pkt allocation timeout in milliseconds. 83 84choice 85 prompt "ESP IP Address configuration" 86 default WIFI_ESP_AT_IP_DHCP 87 help 88 Choose whether to use an IP assigned by DHCP Server or 89 configure a static IP Address. 90 91config WIFI_ESP_AT_IP_DHCP 92 bool "DHCP" 93 help 94 Use DHCP to get an IP Address. 95 96config WIFI_ESP_AT_IP_STATIC 97 bool "Static" 98 help 99 Setup Static IP Address. 100 101endchoice 102 103if WIFI_ESP_AT_IP_STATIC 104 105config WIFI_ESP_AT_IP_ADDRESS 106 string "ESP Station mode IP Address" 107 108config WIFI_ESP_AT_IP_GATEWAY 109 string "Gateway Address" 110 111config WIFI_ESP_AT_IP_MASK 112 string "Network Mask" 113 114endif 115 116choice WIFI_ESP_AT_VERSION 117 prompt "AT version" 118 default WIFI_ESP_AT_VERSION_2_0 119 help 120 Select which version of AT command set should be used. 121 122config WIFI_ESP_AT_VERSION_1_7 123 bool "AT version 1.7" 124 help 125 Use AT command set version 1.7. 126 127config WIFI_ESP_AT_VERSION_2_0 128 bool "AT version 2.0" 129 help 130 Use AT command set version 2.0. 131 132endchoice 133 134config WIFI_ESP_AT_DNS_USE 135 bool "Use DNS from ESP" 136 depends on DNS_RESOLVER 137 help 138 Fetch DNS servers from ESP chip with AT+CIPDNS? command and apply that 139 list to system DNS resolver. 140 141endif # WIFI_ESP_AT 142