Kconfig.projbuild 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134
  1. menu "Example Configuration"
  2. choice EXAMPLE_USE_ETHERNET
  3. prompt "Ethernet Type"
  4. default EXAMPLE_USE_INTERNAL_ETHERNET if IDF_TARGET_ESP32
  5. default EXAMPLE_USE_DM9051 if !IDF_TARGET_ESP32
  6. help
  7. Select which kind of Ethernet will be used in the example.
  8. config EXAMPLE_USE_INTERNAL_ETHERNET
  9. depends on IDF_TARGET_ESP32
  10. select ETH_USE_ESP32_EMAC
  11. bool "Internal EMAC"
  12. help
  13. Select internal Ethernet MAC controller.
  14. config EXAMPLE_USE_DM9051
  15. bool "DM9051 Module"
  16. select ETH_USE_SPI_ETHERNET
  17. select ETH_SPI_ETHERNET_DM9051
  18. help
  19. Select external SPI-Ethernet module (DM9051).
  20. endchoice
  21. if EXAMPLE_USE_INTERNAL_ETHERNET
  22. choice EXAMPLE_ETH_PHY_MODEL
  23. prompt "Ethernet PHY Device"
  24. default EXAMPLE_ETH_PHY_IP101
  25. help
  26. Select the Ethernet PHY device to use in the example.
  27. config EXAMPLE_ETH_PHY_IP101
  28. bool "IP101"
  29. help
  30. IP101 is a single port 10/100 MII/RMII/TP/Fiber Fast Ethernet Transceiver.
  31. Goto http://www.icplus.com.tw/pp-IP101G.html for more information about it.
  32. config EXAMPLE_ETH_PHY_RTL8201
  33. bool "RTL8201/SR8201"
  34. help
  35. RTL8201F/SR8201F is a single port 10/100Mb Ethernet Transceiver with auto MDIX.
  36. Goto http://www.corechip-sz.com/productsview.asp?id=22 for more information about it.
  37. config EXAMPLE_ETH_PHY_LAN8720
  38. bool "LAN8720"
  39. help
  40. LAN8720A is a small footprint RMII 10/100 Ethernet Transceiver with HP Auto-MDIX Support.
  41. Goto https://www.microchip.com/LAN8720A for more information about it.
  42. config EXAMPLE_ETH_PHY_DP83848
  43. bool "DP83848"
  44. help
  45. DP83848 is a single port 10/100Mb/s Ethernet Physical Layer Transceiver.
  46. Goto http://www.ti.com/product/DP83848J for more information about it.
  47. endchoice
  48. config EXAMPLE_ETH_MDC_GPIO
  49. int "SMI MDC GPIO number"
  50. default 23
  51. help
  52. Set the GPIO number used by SMI MDC.
  53. config EXAMPLE_ETH_MDIO_GPIO
  54. int "SMI MDIO GPIO number"
  55. default 18
  56. help
  57. Set the GPIO number used by SMI MDIO.
  58. endif
  59. if EXAMPLE_USE_DM9051
  60. config EXAMPLE_DM9051_SPI_HOST
  61. int "SPI Host Number"
  62. range 0 2
  63. default 1
  64. help
  65. Set the SPI host used to communicate with the SPI Ethernet Controller.
  66. config EXAMPLE_DM9051_SCLK_GPIO
  67. int "SPI SCLK GPIO number"
  68. range 0 33
  69. default 19
  70. help
  71. Set the GPIO number used by SPI SCLK.
  72. config EXAMPLE_DM9051_MOSI_GPIO
  73. int "SPI MOSI GPIO number"
  74. range 0 33
  75. default 23
  76. help
  77. Set the GPIO number used by SPI MOSI.
  78. config EXAMPLE_DM9051_MISO_GPIO
  79. int "SPI MISO GPIO number"
  80. range 0 33
  81. default 25
  82. help
  83. Set the GPIO number used by SPI MISO.
  84. config EXAMPLE_DM9051_CS_GPIO
  85. int "SPI CS GPIO number"
  86. range 0 33
  87. default 22
  88. help
  89. Set the GPIO number used by SPI CS.
  90. config EXAMPLE_DM9051_SPI_CLOCK_MHZ
  91. int "SPI clock speed (MHz)"
  92. range 5 80
  93. default 20
  94. help
  95. Set the clock speed (MHz) of SPI interface.
  96. config EXAMPLE_DM9051_INT_GPIO
  97. int "Interrupt GPIO number"
  98. default 4
  99. help
  100. Set the GPIO number used by DM9051 interrupt.
  101. endif
  102. config EXAMPLE_ETH_PHY_RST_GPIO
  103. int "PHY Reset GPIO number"
  104. default 5
  105. help
  106. Set the GPIO number used to reset PHY chip.
  107. Set to -1 to disable PHY chip hardware reset.
  108. config EXAMPLE_ETH_PHY_ADDR
  109. int "PHY Address"
  110. range 0 31 if EXAMPLE_USE_INTERNAL_ETHERNET
  111. range 1 1 if !EXAMPLE_USE_INTERNAL_ETHERNET
  112. default 1
  113. help
  114. Set PHY address according your board schematic.
  115. endmenu