Kconfig.projbuild 6.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185
  1. menu "Example Connection Configuration"
  2. choice EXAMPLE_CONNECT_INTERFACE
  3. prompt "Connect using"
  4. default EXAMPLE_CONNECT_WIFI
  5. help
  6. Protocol examples can use Wi-Fi or Ethernet to connect to the network.
  7. Choose which interface to use.
  8. config EXAMPLE_CONNECT_WIFI
  9. bool "Wi-Fi"
  10. config EXAMPLE_CONNECT_ETHERNET
  11. bool "Ethernet"
  12. endchoice
  13. if EXAMPLE_CONNECT_WIFI
  14. config EXAMPLE_WIFI_SSID
  15. string "WiFi SSID"
  16. default "myssid"
  17. help
  18. SSID (network name) for the example to connect to.
  19. config EXAMPLE_WIFI_PASSWORD
  20. string "WiFi Password"
  21. default "mypassword"
  22. help
  23. WiFi password (WPA or WPA2) for the example to use.
  24. Can be left blank if the network has no security set.
  25. endif
  26. if EXAMPLE_CONNECT_ETHERNET
  27. choice EXAMPLE_USE_ETHERNET
  28. prompt "Ethernet Type"
  29. default EXAMPLE_USE_INTERNAL_ETHERNET if IDF_TARGET_ESP32
  30. default EXAMPLE_USE_DM9051 if !IDF_TARGET_ESP32
  31. help
  32. Select which kind of Ethernet will be used in the example.
  33. config EXAMPLE_USE_INTERNAL_ETHERNET
  34. depends on IDF_TARGET_ESP32
  35. select ETH_USE_ESP32_EMAC
  36. bool "Internal EMAC"
  37. help
  38. Select internal Ethernet MAC controller.
  39. config EXAMPLE_USE_DM9051
  40. bool "DM9051 Module"
  41. select ETH_USE_SPI_ETHERNET
  42. select ETH_SPI_ETHERNET_DM9051
  43. help
  44. Select external SPI-Ethernet module.
  45. config EXAMPLE_USE_OPENETH
  46. bool "OpenCores Ethernet MAC (EXPERIMENTAL)"
  47. select ETH_USE_OPENETH
  48. help
  49. When this option is enabled, the example is built with support for
  50. OpenCores Ethernet MAC, which allows testing the example in QEMU.
  51. Note that this option is used for internal testing purposes, and
  52. not officially supported. Examples built with this option enabled
  53. will not run on a real ESP32 chip.
  54. endchoice
  55. if EXAMPLE_USE_INTERNAL_ETHERNET
  56. choice EXAMPLE_ETH_PHY_MODEL
  57. prompt "Ethernet PHY Device"
  58. default EXAMPLE_ETH_PHY_IP101
  59. help
  60. Select the Ethernet PHY device to use in the example.
  61. config EXAMPLE_ETH_PHY_IP101
  62. bool "IP101"
  63. help
  64. IP101 is a single port 10/100 MII/RMII/TP/Fiber Fast Ethernet Transceiver.
  65. Goto http://www.icplus.com.tw/pp-IP101G.html for more information about it.
  66. config EXAMPLE_ETH_PHY_RTL8201
  67. bool "RTL8201/SR8201"
  68. help
  69. RTL8201F/SR8201F is a single port 10/100Mb Ethernet Transceiver with auto MDIX.
  70. Goto http://www.corechip-sz.com/productsview.asp?id=22 for more information about it.
  71. config EXAMPLE_ETH_PHY_LAN8720
  72. bool "LAN8720"
  73. help
  74. LAN8720A is a small footprint RMII 10/100 Ethernet Transceiver with HP Auto-MDIX Support.
  75. Goto https://www.microchip.com/LAN8720A for more information about it.
  76. config EXAMPLE_ETH_PHY_DP83848
  77. bool "DP83848"
  78. help
  79. DP83848 is a single port 10/100Mb/s Ethernet Physical Layer Transceiver.
  80. Goto http://www.ti.com/product/DP83848J for more information about it.
  81. endchoice
  82. config EXAMPLE_ETH_MDC_GPIO
  83. int "SMI MDC GPIO number"
  84. default 23
  85. help
  86. Set the GPIO number used by SMI MDC.
  87. config EXAMPLE_ETH_MDIO_GPIO
  88. int "SMI MDIO GPIO number"
  89. default 18
  90. help
  91. Set the GPIO number used by SMI MDIO.
  92. endif
  93. if EXAMPLE_USE_DM9051
  94. config EXAMPLE_DM9051_SPI_HOST
  95. int "SPI Host Number"
  96. range 0 2
  97. default 1
  98. help
  99. Set the SPI host used to communicate with DM9051.
  100. config EXAMPLE_DM9051_SCLK_GPIO
  101. int "SPI SCLK GPIO number"
  102. range 0 33
  103. default 19
  104. help
  105. Set the GPIO number used by SPI SCLK.
  106. config EXAMPLE_DM9051_MOSI_GPIO
  107. int "SPI MOSI GPIO number"
  108. range 0 33
  109. default 23
  110. help
  111. Set the GPIO number used by SPI MOSI.
  112. config EXAMPLE_DM9051_MISO_GPIO
  113. int "SPI MISO GPIO number"
  114. range 0 33
  115. default 25
  116. help
  117. Set the GPIO number used by SPI MISO.
  118. config EXAMPLE_DM9051_CS_GPIO
  119. int "SPI CS GPIO number"
  120. range 0 33
  121. default 22
  122. help
  123. Set the GPIO number used by SPI CS.
  124. config EXAMPLE_DM9051_SPI_CLOCK_MHZ
  125. int "SPI clock speed (MHz)"
  126. range 20 80
  127. default 20
  128. help
  129. Set the clock speed (MHz) of SPI interface.
  130. config EXAMPLE_DM9051_INT_GPIO
  131. int "Interrupt GPIO number"
  132. default 4
  133. help
  134. Set the GPIO number used by DM9051 interrupt.
  135. endif
  136. config EXAMPLE_ETH_PHY_RST_GPIO
  137. int "PHY Reset GPIO number"
  138. default 5
  139. help
  140. Set the GPIO number used to reset PHY chip.
  141. Set to -1 to disable PHY chip hardware reset.
  142. config EXAMPLE_ETH_PHY_ADDR
  143. int "PHY Address"
  144. range 0 31 if EXAMPLE_USE_INTERNAL_ETHERNET
  145. range 1 1 if !EXAMPLE_USE_INTERNAL_ETHERNET
  146. default 1
  147. help
  148. Set PHY address according your board schematic.
  149. endif
  150. config EXAMPLE_CONNECT_IPV6
  151. bool "Obtain IPv6 link-local address"
  152. depends on IDF_TARGET_ESP32
  153. # ToDo: remove once IPV6 is supported on esp32s2
  154. default y
  155. help
  156. By default, examples will wait until IPv4 and IPv6 addresses are obtained.
  157. Disable this option if the network does not support IPv6.
  158. endmenu