Kconfig 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509
  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. depends on !FREERTOS_PLACE_FUNCTIONS_INTO_FLASH
  58. select SPI_MASTER_ISR_IN_IRAM
  59. help
  60. Normally only the ISR of SPI master is placed in the IRAM, so that it
  61. can work without the flash when interrupt is triggered.
  62. For other functions, there's some possibility that the flash cache
  63. miss when running inside and out of SPI functions, which may increase
  64. the interval of SPI transactions.
  65. Enable this to put ``queue_trans``, ``get_trans_result`` and
  66. ``transmit`` functions into the IRAM to avoid possible cache miss.
  67. This configuration won't be available if `CONFIG_FREERTOS_PLACE_FUNCTIONS_INTO_FLASH` is enabled.
  68. During unit test, this is enabled to measure the ideal case of api.
  69. config SPI_MASTER_ISR_IN_IRAM
  70. bool "Place SPI master ISR function into IRAM"
  71. default y
  72. select PERIPH_CTRL_FUNC_IN_IRAM
  73. help
  74. Place the SPI master ISR in to IRAM to avoid possible cache miss.
  75. Also you can forbid the ISR being disabled during flash writing
  76. access, by add ESP_INTR_FLAG_IRAM when initializing the driver.
  77. config SPI_SLAVE_IN_IRAM
  78. bool "Place transmitting functions of SPI slave into IRAM"
  79. default n
  80. select SPI_SLAVE_ISR_IN_IRAM
  81. help
  82. Normally only the ISR of SPI slave is placed in the IRAM, so that it
  83. can work without the flash when interrupt is triggered.
  84. For other functions, there's some possibility that the flash cache
  85. miss when running inside and out of SPI functions, which may increase
  86. the interval of SPI transactions.
  87. Enable this to put ``queue_trans``, ``get_trans_result`` and
  88. ``transmit`` functions into the IRAM to avoid possible cache miss.
  89. config SPI_SLAVE_ISR_IN_IRAM
  90. bool "Place SPI slave ISR function into IRAM"
  91. default y
  92. select PERIPH_CTRL_FUNC_IN_IRAM
  93. help
  94. Place the SPI slave ISR in to IRAM to avoid possible cache miss.
  95. Also you can forbid the ISR being disabled during flash writing
  96. access, by add ESP_INTR_FLAG_IRAM when initializing the driver.
  97. endmenu # SPI Configuration
  98. menu "TWAI Configuration"
  99. depends on SOC_TWAI_SUPPORTED
  100. config TWAI_ISR_IN_IRAM
  101. bool "Place TWAI ISR function into IRAM"
  102. default n
  103. select PERIPH_CTRL_FUNC_IN_IRAM if TWAI_ERRATA_FIX_RX_FRAME_INVALID || TWAI_ERRATA_FIX_RX_FIFO_CORRUPT
  104. help
  105. Place the TWAI ISR in to IRAM. This will allow the ISR to avoid
  106. cache misses, and also be able to run whilst the cache is disabled
  107. (such as when writing to SPI Flash).
  108. Note that if this option is enabled:
  109. - Users should also set the ESP_INTR_FLAG_IRAM in the driver
  110. configuration structure when installing the driver (see docs for
  111. specifics).
  112. - Alert logging (i.e., setting of the TWAI_ALERT_AND_LOG flag)
  113. will have no effect.
  114. config TWAI_ERRATA_FIX_BUS_OFF_REC
  115. bool "Add SW workaround for REC change during bus-off"
  116. depends on IDF_TARGET_ESP32
  117. default y
  118. help
  119. When the bus-off condition is reached, the REC should be reset to 0 and frozen (via LOM) by the
  120. driver's ISR. However on the ESP32, there is an edge case where the REC will increase before the
  121. driver's ISR can respond in time (e.g., due to the rapid occurrence of bus errors), thus causing the
  122. REC to be non-zero after bus-off. A non-zero REC can prevent bus-off recovery as the bus-off recovery
  123. condition is that both TEC and REC become 0. Enabling this option will add a workaround in the driver
  124. to forcibly reset REC to zero on reaching bus-off.
  125. config TWAI_ERRATA_FIX_TX_INTR_LOST
  126. bool "Add SW workaround for TX interrupt lost errata"
  127. depends on IDF_TARGET_ESP32
  128. default y
  129. help
  130. On the ESP32, when a transmit interrupt occurs, and interrupt register is read on the same APB clock
  131. cycle, the transmit interrupt could be lost. Enabling this option will add a workaround that checks the
  132. transmit buffer status bit to recover any lost transmit interrupt.
  133. config TWAI_ERRATA_FIX_RX_FRAME_INVALID
  134. bool "Add SW workaround for invalid RX frame errata"
  135. depends on IDF_TARGET_ESP32
  136. default y
  137. help
  138. On the ESP32, when receiving a data or remote frame, if a bus error occurs in the data or CRC field,
  139. the data of the next received frame could be invalid. Enabling this option will add a workaround that
  140. will reset the peripheral on detection of this errata condition. Note that if a frame is transmitted on
  141. the bus whilst the reset is ongoing, the message will not be receive by the peripheral sent on the bus
  142. during the reset, the message will be lost.
  143. config TWAI_ERRATA_FIX_RX_FIFO_CORRUPT
  144. bool "Add SW workaround for RX FIFO corruption errata"
  145. depends on IDF_TARGET_ESP32
  146. default y
  147. help
  148. On the ESP32, when the RX FIFO overruns and the RX message counter maxes out at 64 messages, the entire
  149. RX FIFO is no longer recoverable. Enabling this option will add a workaround that resets the peripheral
  150. on detection of this errata condition. Note that if a frame is being sent on the bus during the reset
  151. bus during the reset, the message will be lost.
  152. config TWAI_ERRATA_FIX_LISTEN_ONLY_DOM
  153. bool "Add SW workaround for listen only transmits dominant bit errata"
  154. depends on IDF_TARGET_ESP32 || IDF_TARGET_ESP32S2 || IDF_TARGET_ESP32S3 || IDF_TARGET_ESP32C3
  155. default y
  156. help
  157. When in the listen only mode, the TWAI controller must not influence the TWAI bus (i.e., must not send
  158. any dominant bits). However, while in listen only mode on the ESP32/ESP32-S2/ESP32-S3/ESP32-C3, the
  159. TWAI controller will still transmit dominant bits when it detects an error (i.e., as part of an active
  160. error frame). Enabling this option will add a workaround that forces the TWAI controller into an error
  161. passive state on initialization, thus preventing any dominant bits from being sent.
  162. endmenu # TWAI Configuration
  163. menu "Temperature sensor Configuration"
  164. depends on SOC_TEMP_SENSOR_SUPPORTED
  165. config TEMP_SENSOR_SUPPRESS_DEPRECATE_WARN
  166. bool "Suppress legacy driver deprecated warning"
  167. default n
  168. help
  169. Wether to suppress the deprecation warnings when using legacy temperature sensor driver
  170. (driver/temp_sensor.h). If you want to continue using the legacy driver,
  171. and don't want to see related deprecation warnings, you can enable this option.
  172. config TEMP_SENSOR_ENABLE_DEBUG_LOG
  173. bool "Enable debug log"
  174. default n
  175. help
  176. Wether to enable the debug log message for temperature sensor driver.
  177. Note that, this option only controls the temperature sensor driver log, won't affect other drivers.
  178. config TEMP_SENSOR_ISR_IRAM_SAFE
  179. depends on SOC_TEMPERATURE_SENSOR_INTR_SUPPORT
  180. bool "Temperature sensor ISR IRAM-Safe"
  181. default n
  182. help
  183. Ensure the Temperature Sensor interrupt is IRAM-Safe by allowing the interrupt handler to be
  184. executable when the cache is disabled (e.g. SPI Flash write).
  185. endmenu # TEMP_SENSOR Configuration
  186. menu "UART Configuration"
  187. config UART_ISR_IN_IRAM
  188. bool "Place UART ISR function into IRAM"
  189. depends on !RINGBUF_PLACE_ISR_FUNCTIONS_INTO_FLASH
  190. default n
  191. help
  192. If this option is not selected, UART interrupt will be disabled for a long time and
  193. may cause data lost when doing spi flash operation.
  194. endmenu # UART Configuration
  195. menu "GPIO Configuration"
  196. config GPIO_ESP32_SUPPORT_SWITCH_SLP_PULL
  197. bool "Support light sleep GPIO pullup/pulldown configuration for ESP32"
  198. depends on IDF_TARGET_ESP32
  199. help
  200. This option is intended to fix the bug that ESP32 is not able to switch to configured
  201. pullup/pulldown mode in sleep.
  202. If this option is selected, chip will automatically emulate the behaviour of switching,
  203. and about 450B of source codes would be placed into IRAM.
  204. config GPIO_CTRL_FUNC_IN_IRAM
  205. bool "Place GPIO control functions into IRAM"
  206. default n
  207. help
  208. Place GPIO control functions (like intr_disable/set_level) into IRAM,
  209. so that these functions can be IRAM-safe and able to be called in the other IRAM interrupt context.
  210. endmenu # GPIO Configuration
  211. menu "Sigma Delta Modulator Configuration"
  212. depends on SOC_SDM_SUPPORTED
  213. config SDM_CTRL_FUNC_IN_IRAM
  214. bool "Place SDM control functions into IRAM"
  215. default n
  216. help
  217. Place SDM control functions (like set_duty) into IRAM,
  218. so that these functions can be IRAM-safe and able to be called in the other IRAM interrupt context.
  219. Enabling this option can improve driver performance as well.
  220. config SDM_SUPPRESS_DEPRECATE_WARN
  221. bool "Suppress legacy driver deprecated warning"
  222. default n
  223. help
  224. Wether to suppress the deprecation warnings when using legacy sigma delta driver.
  225. If you want to continue using the legacy driver, and don't want to see related deprecation warnings,
  226. you can enable this option.
  227. config SDM_ENABLE_DEBUG_LOG
  228. bool "Enable debug log"
  229. default n
  230. help
  231. Wether to enable the debug log message for SDM driver.
  232. Note that, this option only controls the SDM driver log, won't affect other drivers.
  233. endmenu # Sigma Delta Modulator Configuration
  234. menu "GPTimer Configuration"
  235. config GPTIMER_CTRL_FUNC_IN_IRAM
  236. bool "Place GPTimer control functions into IRAM"
  237. default n
  238. help
  239. Place GPTimer control functions (like start/stop) into IRAM,
  240. so that these functions can be IRAM-safe and able to be called in the other IRAM interrupt context.
  241. Enabling this option can improve driver performance as well.
  242. config GPTIMER_ISR_IRAM_SAFE
  243. bool "GPTimer ISR IRAM-Safe"
  244. default n
  245. help
  246. Ensure the GPTimer interrupt is IRAM-Safe by allowing the interrupt handler to be
  247. executable when the cache is disabled (e.g. SPI Flash write).
  248. config GPTIMER_SUPPRESS_DEPRECATE_WARN
  249. bool "Suppress legacy driver deprecated warning"
  250. default n
  251. help
  252. Wether to suppress the deprecation warnings when using legacy timer group driver (driver/timer.h).
  253. If you want to continue using the legacy driver, and don't want to see related deprecation warnings,
  254. you can enable this option.
  255. config GPTIMER_ENABLE_DEBUG_LOG
  256. bool "Enable debug log"
  257. default n
  258. help
  259. Wether to enable the debug log message for GPTimer driver.
  260. Note that, this option only controls the GPTimer driver log, won't affect other drivers.
  261. endmenu # GPTimer Configuration
  262. menu "PCNT Configuration"
  263. depends on SOC_PCNT_SUPPORTED
  264. config PCNT_CTRL_FUNC_IN_IRAM
  265. bool "Place PCNT control functions into IRAM"
  266. default n
  267. help
  268. Place PCNT control functions (like start/stop) into IRAM,
  269. so that these functions can be IRAM-safe and able to be called in the other IRAM interrupt context.
  270. Enabling this option can improve driver performance as well.
  271. config PCNT_ISR_IRAM_SAFE
  272. bool "PCNT ISR IRAM-Safe"
  273. default n
  274. help
  275. Ensure the PCNT interrupt is IRAM-Safe by allowing the interrupt handler to be
  276. executable when the cache is disabled (e.g. SPI Flash write).
  277. config PCNT_SUPPRESS_DEPRECATE_WARN
  278. bool "Suppress legacy driver deprecated warning"
  279. default n
  280. help
  281. Wether to suppress the deprecation warnings when using legacy PCNT driver (driver/pcnt.h).
  282. If you want to continue using the legacy driver, and don't want to see related deprecation warnings,
  283. you can enable this option.
  284. config PCNT_ENABLE_DEBUG_LOG
  285. bool "Enable debug log"
  286. default n
  287. help
  288. Wether to enable the debug log message for PCNT driver.
  289. Note that, this option only controls the PCNT driver log, won't affect other drivers.
  290. endmenu # PCNT Configuration
  291. menu "RMT Configuration"
  292. depends on SOC_RMT_SUPPORTED
  293. config RMT_ISR_IRAM_SAFE
  294. bool "RMT ISR IRAM-Safe"
  295. default n
  296. select GDMA_ISR_IRAM_SAFE if SOC_RMT_SUPPORT_DMA # RMT basic functionality relies on GDMA callback
  297. select GDMA_CTRL_FUNC_IN_IRAM if SOC_RMT_SUPPORT_DMA # RMT needs to restart the GDMA in the interrupt
  298. help
  299. Ensure the RMT interrupt is IRAM-Safe by allowing the interrupt handler to be
  300. executable when the cache is disabled (e.g. SPI Flash write).
  301. config RMT_SUPPRESS_DEPRECATE_WARN
  302. bool "Suppress legacy driver deprecated warning"
  303. default n
  304. help
  305. Wether to suppress the deprecation warnings when using legacy rmt driver (driver/rmt.h).
  306. If you want to continue using the legacy driver, and don't want to see related deprecation warnings,
  307. you can enable this option.
  308. config RMT_ENABLE_DEBUG_LOG
  309. bool "Enable debug log"
  310. default n
  311. help
  312. Wether to enable the debug log message for RMT driver.
  313. Note that, this option only controls the RMT driver log, won't affect other drivers.
  314. endmenu # RMT Configuration
  315. menu "MCPWM Configuration"
  316. depends on SOC_MCPWM_SUPPORTED
  317. config MCPWM_ISR_IRAM_SAFE
  318. bool "Place MCPWM ISR function into IRAM"
  319. default n
  320. help
  321. This will ensure the MCPWM interrupt handle is IRAM-Safe, allow to avoid flash
  322. cache misses, and also be able to run whilst the cache is disabled.
  323. (e.g. SPI Flash write)
  324. config MCPWM_CTRL_FUNC_IN_IRAM
  325. bool "Place MCPWM control functions into IRAM"
  326. default n
  327. help
  328. Place MCPWM control functions (like set_compare_value) into IRAM,
  329. so that these functions can be IRAM-safe and able to be called in the other IRAM interrupt context.
  330. Enabling this option can improve driver performance as well.
  331. config MCPWM_SUPPRESS_DEPRECATE_WARN
  332. bool "Suppress leagcy driver deprecated warning"
  333. default n
  334. help
  335. Wether to suppress the deprecation warnings when using legacy MCPWM driver (driver/mcpwm.h).
  336. If you want to continue using the legacy driver, and don't want to see related deprecation warnings,
  337. you can enable this option.
  338. config MCPWM_ENABLE_DEBUG_LOG
  339. bool "Enable debug log"
  340. default n
  341. help
  342. Wether to enable the debug log message for MCPWM driver.
  343. Note that, this option only controls the MCPWM driver log, won't affect other drivers.
  344. endmenu # MCPWM Configuration
  345. menu "I2S Configuration"
  346. depends on SOC_I2S_SUPPORTED
  347. config I2S_ISR_IRAM_SAFE
  348. bool "I2S ISR IRAM-Safe"
  349. default n
  350. help
  351. Ensure the I2S interrupt is IRAM-Safe by allowing the interrupt handler to be
  352. executable when the cache is disabled (e.g. SPI Flash write).
  353. config I2S_SUPPRESS_DEPRECATE_WARN
  354. bool "Suppress leagcy driver deprecated warning"
  355. default n
  356. help
  357. Enable this option will suppress the deprecation warnings of using APIs in legacy I2S driver.
  358. config I2S_ENABLE_DEBUG_LOG
  359. bool "Enable I2S debug log"
  360. default n
  361. help
  362. Wether to enable the debug log message for I2S driver.
  363. Note that, this option only controls the I2S driver log, will not affect other drivers.
  364. endmenu # I2S Configuration
  365. menu "DAC Configuration"
  366. depends on SOC_DAC_SUPPORTED
  367. config DAC_CTRL_FUNC_IN_IRAM
  368. bool "Place DAC control functions into IRAM"
  369. default n
  370. help
  371. Place DAC control functions (e.g. 'dac_oneshot_output_voltage') into IRAM,
  372. so that this function can be IRAM-safe and able to be called in the other IRAM interrupt context.
  373. Enabling this option can improve driver performance as well.
  374. config DAC_ISR_IRAM_SAFE
  375. bool "DAC ISR IRAM-Safe"
  376. default n
  377. help
  378. Ensure the DAC interrupt is IRAM-Safe by allowing the interrupt handler to be
  379. executable when the cache is disabled (e.g. SPI Flash write).
  380. config DAC_SUPPRESS_DEPRECATE_WARN
  381. bool "Suppress legacy driver deprecated warning"
  382. default n
  383. help
  384. Wether to suppress the deprecation warnings when using legacy DAC driver (driver/dac.h).
  385. If you want to continue using the legacy driver, and don't want to see related deprecation warnings,
  386. you can enable this option.
  387. config DAC_ENABLE_DEBUG_LOG
  388. bool "Enable debug log"
  389. default n
  390. help
  391. Wether to enable the debug log message for DAC driver.
  392. Note that, this option only controls the DAC driver log, won't affect other drivers.
  393. config DAC_DMA_AUTO_16BIT_ALIGN
  394. bool "Align the continuous data to 16 bit automatically"
  395. depends on SOC_DAC_DMA_16BIT_ALIGN
  396. default y
  397. help
  398. Whether to left shift the continuous data to align every bytes to 16 bits in the driver.
  399. On ESP32, although the DAC resolution is only 8 bits,
  400. the hardware requires 16 bits data in continuous mode.
  401. By enabling this option, the driver will left shift 8 bits for the input data automatically.
  402. Only disable this option when you decide to do this step by yourself.
  403. Note that the driver will allocate a new piece of memory to save the converted data.
  404. endmenu # DAC Configuration
  405. menu "USB Serial/JTAG Configuration"
  406. depends on SOC_USB_SERIAL_JTAG_SUPPORTED
  407. config USJ_NO_AUTO_LS_ON_CONNECTION
  408. bool "Don't enter the automatic light sleep when USB Serial/JTAG port is connected"
  409. depends on PM_ENABLE && ESP_CONSOLE_USB_SERIAL_JTAG_ENABLED && !SOC_USB_SERIAL_JTAG_SUPPORT_LIGHT_SLEEP
  410. default n
  411. help
  412. If enabled, the chip will constantly monitor the connection status of the USB Serial/JTAG port. As long
  413. as the USB Serial/JTAG is connected, a ESP_PM_NO_LIGHT_SLEEP power management lock will be acquired to
  414. prevent the system from entering light sleep.
  415. This option can be useful if serial monitoring is needed via USB Serial/JTAG while power management is
  416. enabled, as the USB Serial/JTAG cannot work under light sleep and after waking up from light sleep.
  417. Note. This option can only control the automatic Light-Sleep behavior. If esp_light_sleep_start() is
  418. called manually from the program, enabling this option will not prevent light sleep entry even if the
  419. USB Serial/JTAG is in use.
  420. endmenu # USB Serial/JTAG Configuration
  421. menu "Parallel IO Configuration"
  422. depends on SOC_PARLIO_SUPPORTED
  423. config PARLIO_ENABLE_DEBUG_LOG
  424. bool "Enable debug log"
  425. default n
  426. help
  427. Wether to enable the debug log message for parallel IO driver.
  428. Note that, this option only controls the parallel IO driver log, won't affect other drivers.
  429. config PARLIO_ISR_IRAM_SAFE
  430. bool "Parallel IO ISR IRAM-Safe"
  431. default n
  432. select GDMA_CTRL_FUNC_IN_IRAM # the driver needs to start the GDMA in the interrupt
  433. help
  434. Ensure the Parallel IO interrupt is IRAM-Safe by allowing the interrupt handler to be
  435. executable when the cache is disabled (e.g. SPI Flash write).
  436. endmenu # Parallel IO Configuration
  437. endmenu # Driver configurations