Kconfig 18 KB

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