Kconfig.projbuild 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151
  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_SPI_ETHERNET 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_SPI_ETHERNET
  40. bool "SPI Ethernet Module"
  41. select ETH_USE_SPI_ETHERNET
  42. help
  43. Select external SPI-Ethernet module.
  44. config EXAMPLE_USE_OPENETH
  45. bool "OpenCores Ethernet MAC (EXPERIMENTAL)"
  46. select ETH_USE_OPENETH
  47. help
  48. When this option is enabled, the example is built with support for
  49. OpenCores Ethernet MAC, which allows testing the example in QEMU.
  50. Note that this option is used for internal testing purposes, and
  51. not officially supported. Examples built with this option enabled
  52. will not run on a real ESP32 chip.
  53. endchoice
  54. if EXAMPLE_USE_INTERNAL_ETHERNET
  55. choice EXAMPLE_ETH_PHY_MODEL
  56. prompt "Ethernet PHY Device"
  57. default EXAMPLE_ETH_PHY_IP101
  58. help
  59. Select the Ethernet PHY device to use in the example.
  60. config EXAMPLE_ETH_PHY_IP101
  61. bool "IP101"
  62. help
  63. IP101 is a single port 10/100 MII/RMII/TP/Fiber Fast Ethernet Transceiver.
  64. Goto http://www.icplus.com.tw/pp-IP101G.html for more information about it.
  65. config EXAMPLE_ETH_PHY_RTL8201
  66. bool "RTL8201/SR8201"
  67. help
  68. RTL8201F/SR8201F is a single port 10/100Mb Ethernet Transceiver with auto MDIX.
  69. Goto http://www.corechip-sz.com/productsview.asp?id=22 for more information about it.
  70. config EXAMPLE_ETH_PHY_LAN8720
  71. bool "LAN8720"
  72. help
  73. LAN8720A is a small footprint RMII 10/100 Ethernet Transceiver with HP Auto-MDIX Support.
  74. Goto https://www.microchip.com/LAN8720A for more information about it.
  75. config EXAMPLE_ETH_PHY_DP83848
  76. bool "DP83848"
  77. help
  78. DP83848 is a single port 10/100Mb/s Ethernet Physical Layer Transceiver.
  79. Goto http://www.ti.com/product/DP83848J for more information about it.
  80. endchoice
  81. endif
  82. if EXAMPLE_USE_SPI_ETHERNET
  83. config EXAMPLE_ETH_SPI_HOST
  84. int "SPI Host Number"
  85. range 0 2
  86. default 1
  87. help
  88. Set the SPI host used to communicate with DM9051.
  89. config EXAMPLE_ETH_SCLK_GPIO
  90. int "SPI SCLK GPIO number"
  91. range 0 33
  92. default 19
  93. help
  94. Set the GPIO number used by SPI SCLK.
  95. config EXAMPLE_ETH_MOSI_GPIO
  96. int "SPI MOSI GPIO number"
  97. range 0 33
  98. default 23
  99. help
  100. Set the GPIO number used by SPI MOSI.
  101. config EXAMPLE_ETH_MISO_GPIO
  102. int "SPI MISO GPIO number"
  103. range 0 33
  104. default 25
  105. help
  106. Set the GPIO number used by SPI MISO.
  107. config EXAMPLE_ETH_CS_GPIO
  108. int "SPI CS GPIO number"
  109. range 0 33
  110. default 22
  111. help
  112. Set the GPIO number used by SPI CS.
  113. config EXAMPLE_ETH_SPI_CLOCK_MHZ
  114. int "SPI clock speed (MHz)"
  115. range 20 80
  116. default 20
  117. help
  118. Set the clock speed (MHz) of SPI interface.
  119. endif
  120. endif
  121. config EXAMPLE_CONNECT_IPV6
  122. bool "Obtain IPv6 link-local address"
  123. depends on IDF_TARGET_ESP32
  124. # ToDo: remove once IPV6 is supported on esp32s2
  125. default y
  126. help
  127. By default, examples will wait until IPv4 and IPv6 addresses are obtained.
  128. Disable this option if the network does not support IPv6.
  129. endmenu