system.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2019 Gunar Schorcht
3  *
4  * This file is subject to the terms and conditions of the GNU Lesser
5  * General Public License v2.1. See the file LICENSE in the top level
6  * directory for more details.
7  */
8 
20 #ifndef SYSTEM_H
21 #define SYSTEM_H
22 
23 #ifndef DOXYGEN
24 
25 #include <stdint.h>
26 #include <stdarg.h>
27 
28 #include "esp_task_wdt.h"
29 #include "sdk/ets.h"
30 
31 #ifdef __cplusplus
32 extern "C" {
33 #endif
34 
40 extern uint8_t system_get_cpu_freq(void);
41 extern void system_update_cpu_freq(uint8_t);
42 extern uint32_t system_get_chip_id(void);
43 extern const char* system_get_sdk_version(void);
44 
45 extern void system_deep_sleep(uint32_t time_in_us);
46 extern void system_restart(void);
47 
48 #define system_wdt_init esp_task_wdt_init
49 #define system_wdt_feed esp_task_wdt_reset
50 
53 #ifdef __cplusplus
54 }
55 #endif
56 
57 #endif /* DOXYGEN */
58 #endif /* SYSTEM_H */
ets.h
ESP8266 ETS ROM function prototypes.