Merge branch 'bugfix/freertos_systimer_stall_when_cpu_halted' into 'master'

freertos: stall systimer while CPU is in debug mode

See merge request espressif/esp-idf!12063
This commit is contained in:
Ivan Grokhotkov
2021-01-29 07:02:30 +08:00
3 changed files with 12 additions and 0 deletions

View File

@@ -154,6 +154,7 @@ void vPortSetupTimer(void)
systimer_hal_init();
systimer_hal_connect_alarm_counter(SYSTIMER_ALARM_0, SYSTIMER_COUNTER_1);
systimer_hal_enable_counter(SYSTIMER_COUNTER_1);
systimer_hal_counter_can_stall_by_cpu(SYSTIMER_COUNTER_1, 0, true);
systimer_hal_set_alarm_period(SYSTIMER_ALARM_0, 1000000UL / CONFIG_FREERTOS_HZ);
systimer_hal_select_alarm_mode(SYSTIMER_ALARM_0, SYSTIMER_ALARM_MODE_PERIOD);
systimer_hal_enable_alarm_int(SYSTIMER_ALARM_0);