1 /*
2  * SPDX-FileCopyrightText: 2020-2022 Espressif Systems (Shanghai) CO LTD
3  *
4  * SPDX-License-Identifier: Apache-2.0
5  */
6 
7 /*******************************************************************************
8  * NOTICE
9  * The hal is not public api, don't use in application code.
10  * See readme.md in hal/include/hal/readme.md
11  ******************************************************************************/
12 
13 #pragma once
14 
15 #ifdef __cplusplus
16 extern "C" {
17 #endif
18 
19 #include <stddef.h>
20 #include <stdbool.h>
21 #include <stdint.h>
22 #include "soc/soc_caps.h"
23 
24 typedef struct {
25     uint8_t threshold;
26     bool enabled;
27     bool reset_enabled;
28     bool flash_power_down;
29     bool rf_power_down;
30 } brownout_hal_config_t;
31 
32 /**
33  * @brief Config brown out hal.
34  *
35  * @param cfg Pointer of brown out configuration structure.
36  */
37 void brownout_hal_config(const brownout_hal_config_t *cfg);
38 
39 
40 #ifdef __cplusplus
41 }
42 #endif
43