Kconfig 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308
  1. menu "Driver Configurations"
  2. menu "ADC Configuration"
  3. config ADC_FORCE_XPD_FSM
  4. bool "Use the FSM to control ADC power"
  5. default n
  6. help
  7. ADC power can be controlled by the FSM instead of software. This allows the ADC to
  8. be shut off when it is not working leading to lower power consumption. However
  9. using the FSM control ADC power will increase the noise of ADC.
  10. config ADC_DISABLE_DAC
  11. bool "Disable DAC when ADC2 is used on GPIO 25 and 26"
  12. default y
  13. help
  14. If this is set, the ADC2 driver will disable the output of the DAC corresponding to the specified
  15. channel. This is the default value.
  16. For testing, disable this option so that we can measure the output of DAC by internal ADC.
  17. endmenu # ADC Configuration
  18. menu "SPI Configuration"
  19. config SPI_MASTER_IN_IRAM
  20. bool "Place transmitting functions of SPI master into IRAM"
  21. default n
  22. select SPI_MASTER_ISR_IN_IRAM
  23. help
  24. Normally only the ISR of SPI master is placed in the IRAM, so that it
  25. can work without the flash when interrupt is triggered.
  26. For other functions, there's some possibility that the flash cache
  27. miss when running inside and out of SPI functions, which may increase
  28. the interval of SPI transactions.
  29. Enable this to put ``queue_trans``, ``get_trans_result`` and
  30. ``transmit`` functions into the IRAM to avoid possible cache miss.
  31. During unit test, this is enabled to measure the ideal case of api.
  32. config SPI_MASTER_ISR_IN_IRAM
  33. bool "Place SPI master ISR function into IRAM"
  34. default y
  35. help
  36. Place the SPI master ISR in to IRAM to avoid possible cache miss.
  37. Also you can forbid the ISR being disabled during flash writing
  38. access, by add ESP_INTR_FLAG_IRAM when initializing the driver.
  39. config SPI_SLAVE_IN_IRAM
  40. bool "Place transmitting functions of SPI slave into IRAM"
  41. default n
  42. select SPI_SLAVE_ISR_IN_IRAM
  43. help
  44. Normally only the ISR of SPI slave is placed in the IRAM, so that it
  45. can work without the flash when interrupt is triggered.
  46. For other functions, there's some possibility that the flash cache
  47. miss when running inside and out of SPI functions, which may increase
  48. the interval of SPI transactions.
  49. Enable this to put ``queue_trans``, ``get_trans_result`` and
  50. ``transmit`` functions into the IRAM to avoid possible cache miss.
  51. config SPI_SLAVE_ISR_IN_IRAM
  52. bool "Place SPI slave ISR function into IRAM"
  53. default y
  54. help
  55. Place the SPI slave ISR in to IRAM to avoid possible cache miss.
  56. Also you can forbid the ISR being disabled during flash writing
  57. access, by add ESP_INTR_FLAG_IRAM when initializing the driver.
  58. endmenu # SPI Configuration
  59. menu "TWAI Configuration"
  60. depends on SOC_TWAI_SUPPORTED
  61. config TWAI_ISR_IN_IRAM
  62. bool "Place TWAI ISR function into IRAM"
  63. default n
  64. select PERIPH_CTRL_FUNC_IN_IRAM if TWAI_ERRATA_FIX_RX_FRAME_INVALID || TWAI_ERRATA_FIX_RX_FIFO_CORRUPT
  65. help
  66. Place the TWAI ISR in to IRAM. This will allow the ISR to avoid
  67. cache misses, and also be able to run whilst the cache is disabled
  68. (such as when writing to SPI Flash).
  69. Note that if this option is enabled:
  70. - Users should also set the ESP_INTR_FLAG_IRAM in the driver
  71. configuration structure when installing the driver (see docs for
  72. specifics).
  73. - Alert logging (i.e., setting of the TWAI_ALERT_AND_LOG flag)
  74. will have no effect.
  75. config TWAI_ERRATA_FIX_BUS_OFF_REC
  76. bool "Add SW workaround for REC change during bus-off"
  77. depends on IDF_TARGET_ESP32
  78. default y
  79. help
  80. When the bus-off condition is reached, the REC should be reset to 0 and frozen (via LOM) by the
  81. driver's ISR. However on the ESP32, there is an edge case where the REC will increase before the
  82. driver's ISR can respond in time (e.g., due to the rapid occurrence of bus errors), thus causing the
  83. REC to be non-zero after bus-off. A non-zero REC can prevent bus-off recovery as the bus-off recovery
  84. condition is that both TEC and REC become 0. Enabling this option will add a workaround in the driver
  85. to forcibly reset REC to zero on reaching bus-off.
  86. config TWAI_ERRATA_FIX_TX_INTR_LOST
  87. bool "Add SW workaround for TX interrupt lost errata"
  88. depends on IDF_TARGET_ESP32
  89. default y
  90. help
  91. On the ESP32, when a transmit interrupt occurs, and interrupt register is read on the same APB clock
  92. cycle, the transmit interrupt could be lost. Enabling this option will add a workaround that checks the
  93. transmit buffer status bit to recover any lost transmit interrupt.
  94. config TWAI_ERRATA_FIX_RX_FRAME_INVALID
  95. bool "Add SW workaround for invalid RX frame errata"
  96. depends on IDF_TARGET_ESP32
  97. default y
  98. help
  99. On the ESP32, when receiving a data or remote frame, if a bus error occurs in the data or CRC field,
  100. the data of the next received frame could be invalid. Enabling this option will add a workaround that
  101. will reset the peripheral on detection of this errata condition. Note that if a frame is transmitted on
  102. the bus whilst the reset is ongoing, the message will not be receive by the peripheral sent on the bus
  103. during the reset, the message will be lost.
  104. config TWAI_ERRATA_FIX_RX_FIFO_CORRUPT
  105. bool "Add SW workaround for RX FIFO corruption errata"
  106. depends on IDF_TARGET_ESP32
  107. default y
  108. help
  109. On the ESP32, when the RX FIFO overruns and the RX message counter maxes out at 64 messages, the entire
  110. RX FIFO is no longer recoverable. Enabling this option will add a workaround that resets the peripheral
  111. on detection of this errata condition. Note that if a frame is being sent on the bus during the reset
  112. bus during the reset, the message will be lost.
  113. endmenu # TWAI Configuration
  114. menu "Temperature sensor Configuration"
  115. depends on SOC_TEMP_SENSOR_SUPPORTED
  116. config TEMP_SENSOR_SUPPRESS_DEPRECATE_WARN
  117. bool "Suppress legacy driver deprecated warning"
  118. default n
  119. help
  120. Wether to suppress the deprecation warnings when using legacy temperature sensor driver
  121. (driver/temp_sensor.h). If you want to continue using the legacy driver,
  122. and don't want to see related deprecation warnings, you can enable this option.
  123. config TEMP_SENSOR_ENABLE_DEBUG_LOG
  124. bool "Enable debug log"
  125. default n
  126. help
  127. Wether to enable the debug log message for temperature sensor driver.
  128. Note that, this option only controls the temperature sensor driver log, won't affect other drivers.
  129. endmenu # TEMP_SENSOR Configuration
  130. menu "UART Configuration"
  131. config UART_ISR_IN_IRAM
  132. bool "Place UART ISR function into IRAM"
  133. default n
  134. help
  135. If this option is not selected, UART interrupt will be disabled for a long time and
  136. may cause data lost when doing spi flash operation.
  137. endmenu # UART Configuration
  138. menu "GPIO Configuration"
  139. config GPIO_ESP32_SUPPORT_SWITCH_SLP_PULL
  140. bool "Support light sleep GPIO pullup/pulldown configuration for ESP32"
  141. depends on IDF_TARGET_ESP32
  142. help
  143. This option is intended to fix the bug that ESP32 is not able to switch to configured
  144. pullup/pulldown mode in sleep.
  145. If this option is selected, chip will automatically emulate the behaviour of switching,
  146. and about 450B of source codes would be placed into IRAM.
  147. config GPIO_CTRL_FUNC_IN_IRAM
  148. bool "Place GPIO control functions into IRAM"
  149. default n
  150. help
  151. Place GPIO control functions (like intr_disable/set_level) into IRAM,
  152. so that these functions can be IRAM-safe and able to be called in the other IRAM interrupt context.
  153. endmenu # GPIO Configuration
  154. menu "GDMA Configuration"
  155. depends on SOC_GDMA_SUPPORTED
  156. config GDMA_CTRL_FUNC_IN_IRAM
  157. bool "Place GDMA control functions into IRAM"
  158. default n
  159. help
  160. Place GDMA control functions (like start/stop/append/reset) into IRAM,
  161. so that these functions can be IRAM-safe and able to be called in the other IRAM interrupt context.
  162. Enabling this option can improve driver performance as well.
  163. config GDMA_ISR_IRAM_SAFE
  164. bool "GDMA ISR IRAM-Safe"
  165. default n
  166. help
  167. This will ensure the GDMA interrupt handler is IRAM-Safe, allow to avoid flash
  168. cache misses, and also be able to run whilst the cache is disabled.
  169. (e.g. SPI Flash write).
  170. endmenu # GDMA Configuration
  171. menu "GPTimer Configuration"
  172. config GPTIMER_CTRL_FUNC_IN_IRAM
  173. bool "Place GPTimer control functions into IRAM"
  174. default n
  175. help
  176. Place GPTimer control functions (like start/stop) into IRAM,
  177. so that these functions can be IRAM-safe and able to be called in the other IRAM interrupt context.
  178. Enabling this option can improve driver performance as well.
  179. config GPTIMER_ISR_IRAM_SAFE
  180. bool "GPTimer ISR IRAM-Safe"
  181. default n
  182. help
  183. Ensure the GPTimer interrupt is IRAM-Safe by allowing the interrupt handler to be
  184. executable when the cache is disabled (e.g. SPI Flash write).
  185. config GPTIMER_SUPPRESS_DEPRECATE_WARN
  186. bool "Suppress legacy driver deprecated warning"
  187. default n
  188. help
  189. Wether to suppress the deprecation warnings when using legacy timer group driver (driver/timer.h).
  190. If you want to continue using the legacy driver, and don't want to see related deprecation warnings,
  191. you can enable this option.
  192. config GPTIMER_ENABLE_DEBUG_LOG
  193. bool "Enable debug log"
  194. default n
  195. help
  196. Wether to enable the debug log message for GPTimer driver.
  197. Note that, this option only controls the GPTimer driver log, won't affect other drivers.
  198. endmenu # GPTimer Configuration
  199. menu "PCNT Configuration"
  200. depends on SOC_PCNT_SUPPORTED
  201. config PCNT_CTRL_FUNC_IN_IRAM
  202. bool "Place PCNT control functions into IRAM"
  203. default n
  204. help
  205. Place PCNT control functions (like start/stop) into IRAM,
  206. so that these functions can be IRAM-safe and able to be called in the other IRAM interrupt context.
  207. Enabling this option can improve driver performance as well.
  208. config PCNT_ISR_IRAM_SAFE
  209. bool "PCNT ISR IRAM-Safe"
  210. default n
  211. help
  212. Ensure the PCNT interrupt is IRAM-Safe by allowing the interrupt handler to be
  213. executable when the cache is disabled (e.g. SPI Flash write).
  214. config PCNT_SUPPRESS_DEPRECATE_WARN
  215. bool "Suppress legacy driver deprecated warning"
  216. default n
  217. help
  218. Wether to suppress the deprecation warnings when using legacy PCNT driver (driver/pcnt.h).
  219. If you want to continue using the legacy driver, and don't want to see related deprecation warnings,
  220. you can enable this option.
  221. config PCNT_ENABLE_DEBUG_LOG
  222. bool "Enable debug log"
  223. default n
  224. help
  225. Wether to enable the debug log message for PCNT driver.
  226. Note that, this option only controls the PCNT driver log, won't affect other drivers.
  227. endmenu # PCNT Configuration
  228. menu "RMT Configuration"
  229. depends on SOC_RMT_SUPPORTED
  230. config RMT_ISR_IRAM_SAFE
  231. bool "RMT ISR IRAM-Safe"
  232. default n
  233. select GDMA_ISR_IRAM_SAFE if SOC_RMT_SUPPORT_DMA # RMT basic functionality relies on GDMA callback
  234. select GDMA_CTRL_FUNC_IN_IRAM if SOC_RMT_SUPPORT_DMA # RMT needs to restart the GDMA in the interrupt
  235. help
  236. Ensure the RMT interrupt is IRAM-Safe by allowing the interrupt handler to be
  237. executable when the cache is disabled (e.g. SPI Flash write).
  238. config RMT_SUPPRESS_DEPRECATE_WARN
  239. bool "Suppress legacy driver deprecated warning"
  240. default n
  241. help
  242. Wether to suppress the deprecation warnings when using legacy rmt driver (driver/rmt.h).
  243. If you want to continue using the legacy driver, and don't want to see related deprecation warnings,
  244. you can enable this option.
  245. config RMT_ENABLE_DEBUG_LOG
  246. bool "Enable debug log"
  247. default n
  248. help
  249. Wether to enable the debug log message for RMT driver.
  250. Note that, this option only controls the RMT driver log, won't affect other drivers.
  251. endmenu # RMT Configuration
  252. menu "MCPWM Configuration"
  253. depends on SOC_MCPWM_SUPPORTED
  254. config MCPWM_ISR_IRAM_SAFE
  255. bool "Place MCPWM ISR function into IRAM"
  256. default n
  257. help
  258. This will ensure the MCPWM interrupt handle is IRAM-Safe, allow to avoid flash
  259. cache misses, and also be able to run whilst the cache is disabled.
  260. (e.g. SPI Flash write)
  261. endmenu # MCPWM Configuration
  262. endmenu # Driver Configurations