Skip to content

Commit 6eae7bc

Browse files
committed
change(esp_system): trigger digital system reset in brownout isr
1 parent ce7393f commit 6eae7bc

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

components/esp_system/port/brownout.c

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* SPDX-FileCopyrightText: 2015-2023 Espressif Systems (Shanghai) CO LTD
2+
* SPDX-FileCopyrightText: 2015-2024 Espressif Systems (Shanghai) CO LTD
33
*
44
* SPDX-License-Identifier: Apache-2.0
55
*/
@@ -16,6 +16,7 @@
1616
#include "soc/soc.h"
1717
#include "soc/rtc_periph.h"
1818
#include "esp_attr.h"
19+
#include "esp_rom_sys.h"
1920
#include "bootloader_flash.h"
2021
#include "esp_intr_alloc.h"
2122
#include "hal/brownout_hal.h"
@@ -56,7 +57,10 @@ IRAM_ATTR static void rtc_brownout_isr_handler(void *arg)
5657
ESP_DRAM_LOGI(TAG, "Brownout detector was triggered\r\n\r\n");
5758
}
5859

59-
esp_restart_noos();
60+
esp_rom_software_reset_system();
61+
while (true) {
62+
;
63+
}
6064
}
6165
#endif // CONFIG_ESP_SYSTEM_BROWNOUT_INTR
6266

0 commit comments

Comments
 (0)