1 /*
2  * Copyright (C) 2015-2020 Alibaba Group Holding Limited
3  */
4 
5 #include "aos/hal/rtc.h"
6 
7 
8 /**
9  * This function will initialize the on board CPU real time clock
10  *
11  *
12  * @param[in]  rtc  rtc device
13  *
14  * @return  0 : on success, EIO : if an error occurred with any step
15  */
hal_rtc_init(rtc_dev_t * rtc)16 int32_t hal_rtc_init(rtc_dev_t *rtc)
17 {
18 	return 0;
19 }
20 
21 /**
22  * This function will return the value of time read from the on board CPU real time clock.
23  *
24  * @param[in]   rtc   rtc device
25  * @param[out]  time  pointer to a time structure
26  *
27  * @return  0 : on success, EIO : if an error occurred with any step
28  */
hal_rtc_get_time(rtc_dev_t * rtc,rtc_time_t * time)29 int32_t hal_rtc_get_time(rtc_dev_t *rtc, rtc_time_t *time)
30 {
31 	return 0;
32 }
33 
34 /**
35  * This function will set MCU RTC time to a new value.
36  *
37  * @param[in]   rtc   rtc device
38  * @param[out]  time  pointer to a time structure
39  *
40  * @return  0 : on success, EIO : if an error occurred with any step
41  */
hal_rtc_set_time(rtc_dev_t * rtc,const rtc_time_t * time)42 int32_t hal_rtc_set_time(rtc_dev_t *rtc, const rtc_time_t *time)
43 {
44 	return 0;
45 }
46 
47 /**
48  * De-initialises an RTC interface, Turns off an RTC hardware interface
49  *
50  * @param[in]  RTC  the interface which should be de-initialised
51  *
52  * @return  0 : on success, EIO : if an error occurred with any step
53  */
hal_rtc_finalize(rtc_dev_t * rtc)54 int32_t hal_rtc_finalize(rtc_dev_t *rtc)
55 {
56 	return 0;
57 }
58 
59