Kconfig 3.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. menu "High resolution timer (esp_timer)"
  2. config ESP_TIMER_PROFILING
  3. bool "Enable esp_timer profiling features"
  4. default n
  5. help
  6. If enabled, esp_timer_dump will dump information such as number of times the timer was started,
  7. number of times the timer has triggered, and the total time it took for the callback to run.
  8. This option has some effect on timer performance and the amount of memory used for timer
  9. storage, and should only be used for debugging/testing purposes.
  10. config ESP_TIME_FUNCS_USE_RTC_TIMER # [refactor-todo] remove when timekeeping and persistence are separate
  11. bool
  12. config ESP_TIME_FUNCS_USE_ESP_TIMER # [refactor-todo] remove when timekeeping and persistence are separate
  13. bool
  14. config ESP_TIME_FUNCS_USE_NONE # [refactor-todo] remove when timekeeping and persistence are separate
  15. bool
  16. config ESP_TIMER_TASK_STACK_SIZE
  17. int "High-resolution timer task stack size"
  18. default 3584
  19. range 2048 65536
  20. help
  21. Configure the stack size of "timer_task" task. This task is used
  22. to dispatch callbacks of timers created using ets_timer and esp_timer
  23. APIs. If you are seing stack overflow errors in timer task, increase
  24. this value.
  25. Note that this is not the same as FreeRTOS timer task. To configure
  26. FreeRTOS timer task size, see "FreeRTOS timer task stack size" option
  27. in "FreeRTOS" menu.
  28. config ESP_TIMER_INTERRUPT_LEVEL
  29. int "Interrupt level"
  30. default 1
  31. range 1 3 if IDF_TARGET_ESP32
  32. range 1 1 if !IDF_TARGET_ESP32
  33. help
  34. It sets the interrupt level for esp_timer ISR in range 1..3.
  35. A higher level (3) helps to decrease the ISR esp_timer latency.
  36. config ESP_TIMER_SUPPORTS_ISR_DISPATCH_METHOD
  37. bool "Support ISR dispatch method"
  38. default n
  39. help
  40. Allows using ESP_TIMER_ISR dispatch method (ESP_TIMER_TASK dispatch method is also avalible).
  41. - ESP_TIMER_TASK - Timer callbacks are dispatched from a high-priority esp_timer task.
  42. - ESP_TIMER_ISR - Timer callbacks are dispatched directly from the timer interrupt handler.
  43. The ISR dispatch can be used, in some cases, when a callback is very simple
  44. or need a lower-latency.
  45. choice ESP_TIMER_IMPL
  46. prompt "Hardware timer to use for esp_timer"
  47. default ESP_TIMER_IMPL_TG0_LAC if IDF_TARGET_ESP32
  48. default ESP_TIMER_IMPL_SYSTIMER
  49. help
  50. esp_timer APIs can be implemented using different hardware timers.
  51. - "FRC2 (legacy)" implementation has been used in ESP-IDF v2.x - v4.1.
  52. - "LAC timer of Timer Group 0" implementation is simpler, and has smaller
  53. run time overhead because software handling of timer overflow is not needed.
  54. - "SYSTIMER" implementation is similar to "LAC timer of Timer Group 0" but for non ESP32 chips.
  55. config ESP_TIMER_IMPL_FRC2
  56. bool "FRC2 (legacy) timer"
  57. depends on IDF_TARGET_ESP32
  58. config ESP_TIMER_IMPL_TG0_LAC
  59. bool "LAC timer of Timer Group 0"
  60. depends on IDF_TARGET_ESP32
  61. config ESP_TIMER_IMPL_SYSTIMER
  62. bool "SYSTIMER"
  63. depends on !IDF_TARGET_ESP32
  64. endchoice
  65. endmenu # esp_timer