esp_system: introduce system time functions

- Introduce system time function and concept of system time provider.
esp_timer is system time provider when present.
- Set the reference point for system time, g_startup_time.
- Use the system time functions in newlib instead of calling esp_timer
functions directly
This commit is contained in:
Renz Bagaporo
2020-06-23 16:46:06 +08:00
parent 5785e4dfb6
commit 346cf4430d
14 changed files with 172 additions and 31 deletions

View File

@@ -117,3 +117,8 @@ uint64_t esp_timer_impl_get_counter_reg(void);
* @return the value of the alarm register
*/
uint64_t esp_timer_impl_get_alarm_reg(void);
/**
* @brief Initialize and provide system timekeeping functions.
*/
esp_err_t esp_timer_timekeeping_impl_init(void);