1menu "Example Connection Configuration" 2 3 config EXAMPLE_CONNECT_WIFI 4 bool "connect using WiFi interface" 5 default y 6 help 7 Protocol examples can use Wi-Fi and/or Ethernet to connect to the network. 8 Choose this option to connect with WiFi 9 10 if EXAMPLE_CONNECT_WIFI 11 config EXAMPLE_WIFI_SSID 12 string "WiFi SSID" 13 default "myssid" 14 help 15 SSID (network name) for the example to connect to. 16 17 config EXAMPLE_WIFI_PASSWORD 18 string "WiFi Password" 19 default "mypassword" 20 help 21 WiFi password (WPA or WPA2) for the example to use. 22 Can be left blank if the network has no security set. 23 endif 24 25 config EXAMPLE_CONNECT_ETHERNET 26 bool "connect using Ethernet interface" 27 default n 28 help 29 Protocol examples can use Wi-Fi and/or Ethernet to connect to the network. 30 Choose this option to connect with Ethernet 31 32 if EXAMPLE_CONNECT_ETHERNET 33 config EXAMPLE_USE_SPI_ETHERNET 34 bool 35 36 choice EXAMPLE_ETHERNET_TYPE 37 prompt "Ethernet Type" 38 default EXAMPLE_USE_INTERNAL_ETHERNET if IDF_TARGET_ESP32 39 default EXAMPLE_USE_W5500 40 help 41 Select which kind of Ethernet will be used in the example. 42 43 config EXAMPLE_USE_INTERNAL_ETHERNET 44 depends on IDF_TARGET_ESP32 45 select ETH_USE_ESP32_EMAC 46 bool "Internal EMAC" 47 help 48 Select internal Ethernet MAC controller. 49 50 config EXAMPLE_USE_DM9051 51 bool "DM9051 Module" 52 select EXAMPLE_USE_SPI_ETHERNET 53 select ETH_USE_SPI_ETHERNET 54 select ETH_SPI_ETHERNET_DM9051 55 help 56 Select external SPI-Ethernet module. 57 58 config EXAMPLE_USE_W5500 59 bool "W5500 Module" 60 select EXAMPLE_USE_SPI_ETHERNET 61 select ETH_USE_SPI_ETHERNET 62 select ETH_SPI_ETHERNET_W5500 63 help 64 Select external SPI-Ethernet module (W5500). 65 66 config EXAMPLE_USE_OPENETH 67 bool "OpenCores Ethernet MAC (EXPERIMENTAL)" 68 select ETH_USE_OPENETH 69 help 70 When this option is enabled, the example is built with support for 71 OpenCores Ethernet MAC, which allows testing the example in QEMU. 72 Note that this option is used for internal testing purposes, and 73 not officially supported. Examples built with this option enabled 74 will not run on a real ESP32 chip. 75 76 endchoice # EXAMPLE_ETHERNET_TYPE 77 78 if EXAMPLE_USE_INTERNAL_ETHERNET 79 choice EXAMPLE_ETH_PHY_MODEL 80 prompt "Ethernet PHY Device" 81 default EXAMPLE_ETH_PHY_IP101 82 help 83 Select the Ethernet PHY device to use in the example. 84 85 config EXAMPLE_ETH_PHY_IP101 86 bool "IP101" 87 help 88 IP101 is a single port 10/100 MII/RMII/TP/Fiber Fast Ethernet Transceiver. 89 Goto http://www.icplus.com.tw/pp-IP101G.html for more information about it. 90 91 config EXAMPLE_ETH_PHY_RTL8201 92 bool "RTL8201/SR8201" 93 help 94 RTL8201F/SR8201F is a single port 10/100Mb Ethernet Transceiver with auto MDIX. 95 Goto http://www.corechip-sz.com/productsview.asp?id=22 for more information about it. 96 97 config EXAMPLE_ETH_PHY_LAN8720 98 bool "LAN8720" 99 help 100 LAN8720A is a small footprint RMII 10/100 Ethernet Transceiver with HP Auto-MDIX Support. 101 Goto https://www.microchip.com/LAN8720A for more information about it. 102 103 config EXAMPLE_ETH_PHY_DP83848 104 bool "DP83848" 105 help 106 DP83848 is a single port 10/100Mb/s Ethernet Physical Layer Transceiver. 107 Goto http://www.ti.com/product/DP83848J for more information about it. 108 endchoice 109 110 config EXAMPLE_ETH_MDC_GPIO 111 int "SMI MDC GPIO number" 112 default 23 113 help 114 Set the GPIO number used by SMI MDC. 115 116 config EXAMPLE_ETH_MDIO_GPIO 117 int "SMI MDIO GPIO number" 118 default 18 119 help 120 Set the GPIO number used by SMI MDIO. 121 endif 122 123 if EXAMPLE_USE_SPI_ETHERNET 124 config EXAMPLE_ETH_SPI_HOST 125 int "SPI Host Number" 126 range 0 2 127 default 1 128 help 129 Set the SPI host used to communicate with the SPI Ethernet Controller. 130 131 config EXAMPLE_ETH_SPI_SCLK_GPIO 132 int "SPI SCLK GPIO number" 133 range 0 33 134 default 20 135 help 136 Set the GPIO number used by SPI SCLK. 137 138 config EXAMPLE_ETH_SPI_MOSI_GPIO 139 int "SPI MOSI GPIO number" 140 range 0 33 141 default 19 142 help 143 Set the GPIO number used by SPI MOSI. 144 145 config EXAMPLE_ETH_SPI_MISO_GPIO 146 int "SPI MISO GPIO number" 147 range 0 33 148 default 18 149 help 150 Set the GPIO number used by SPI MISO. 151 152 config EXAMPLE_ETH_SPI_CS_GPIO 153 int "SPI CS GPIO number" 154 range 0 33 155 default 21 156 help 157 Set the GPIO number used by SPI CS. 158 159 config EXAMPLE_ETH_SPI_CLOCK_MHZ 160 int "SPI clock speed (MHz)" 161 range 20 80 162 default 36 163 help 164 Set the clock speed (MHz) of SPI interface. 165 166 config EXAMPLE_ETH_SPI_INT_GPIO 167 int "Interrupt GPIO number" 168 default 4 169 help 170 Set the GPIO number used by the SPI Ethernet module interrupt line. 171 endif # EXAMPLE_USE_SPI_ETHERNET 172 173 config EXAMPLE_ETH_PHY_RST_GPIO 174 int "PHY Reset GPIO number" 175 default 5 176 help 177 Set the GPIO number used to reset PHY chip. 178 Set to -1 to disable PHY chip hardware reset. 179 180 config EXAMPLE_ETH_PHY_ADDR 181 int "PHY Address" 182 range 0 31 if EXAMPLE_USE_INTERNAL_ETHERNET 183 default 1 184 help 185 Set PHY address according your board schematic. 186 endif # EXAMPLE_CONNECT_ETHERNET 187 188 config EXAMPLE_CONNECT_IPV6 189 bool "Obtain IPv6 address" 190 default y 191 depends on EXAMPLE_CONNECT_WIFI || EXAMPLE_CONNECT_ETHERNET 192 select LWIP_IPV6 193 help 194 By default, examples will wait until IPv4 and IPv6 local link addresses are obtained. 195 Disable this option if the network does not support IPv6. 196 Choose the preferred IPv6 address type if the connection code should wait until other than 197 the local link address gets assigned. 198 Consider enabling IPv6 stateless address autoconfiguration (SLAAC) in the LWIP component. 199 200 if EXAMPLE_CONNECT_IPV6 201 choice EXAMPLE_CONNECT_PREFERRED_IPV6 202 prompt "Preferred IPv6 Type" 203 default EXAMPLE_CONNECT_IPV6_PREF_LOCAL_LINK 204 help 205 Select which kind of IPv6 address the connect logic waits for. 206 207 config EXAMPLE_CONNECT_IPV6_PREF_LOCAL_LINK 208 bool "Local Link Address" 209 help 210 Blocks until Local link address assigned. 211 212 config EXAMPLE_CONNECT_IPV6_PREF_GLOBAL 213 bool "Global Address" 214 help 215 Blocks until Global address assigned. 216 217 config EXAMPLE_CONNECT_IPV6_PREF_SITE_LOCAL 218 bool "Site Local Address" 219 help 220 Blocks until Site link address assigned. 221 222 config EXAMPLE_CONNECT_IPV6_PREF_UNIQUE_LOCAL 223 bool "Unique Local Link Address" 224 help 225 Blocks until Unique local address assigned. 226 227 endchoice 228 229 endif 230 231 232endmenu 233