| /bsp/cvitek/drivers/ |
| A D | drv_rtc.c | 137 unsigned long sec; in hal_cvi_rtc_get_time_sec() local 146 sec = sec_ro_t; in hal_cvi_rtc_get_time_sec() 150 } else if (sec < 0x30000000) { in hal_cvi_rtc_get_time_sec() 155 *ret_sec = sec; in hal_cvi_rtc_get_time_sec() 226 )*60 + sec; /* finally seconds */ in mktime64() 241 unsigned long sec; in _rtc_get_timeval() local 246 rtc_time64_to_tm(sec, &t); in _rtc_get_timeval() 274 *(time_t *) sec = tv.tv_sec; in _rtc_get_secs() 287 gmtime_r(sec, &tm); in _rtc_set_secs() 326 unsigned long int sec; in _rtc_get_alarm() local [all …]
|
| /bsp/Vango/v85xxp/Libraries/VangoV85xxP_standard_peripheral/Source/ |
| A D | lib_rtc.c | 141 uint32_t subsec,sec,alarmctl; in RTC_SetTime() local 157 sec = sTime->Seconds; in RTC_SetTime() 158 sec = sec - (sec>>4)*6; in RTC_SetTime() 200 uint32_t subsec,sec; in RTC_GetTime() local 225 sec = subsec/32768; in RTC_GetTime() 226 sec = sec + (sec/10)*6; in RTC_GetTime() 227 gTime->Seconds = sec; in RTC_GetTime() 298 sec = sec - (sec>>4)*6; in RTC_SetAlarm() 336 uint32_t sec,subsec; in RTC_GetAlarm() local 352 sec = subsec/32768; in RTC_GetAlarm() [all …]
|
| /bsp/allwinner/libraries/sunxi-hal/include/hal/sdmmc/osal/FreeRTOS/ |
| A D | _os_time.h | 72 #define OS_SecsToTicks(sec) ((OS_Time_t)(sec) * OS_HZ) argument 78 #define OS_SecsToJiffies(sec) OS_SecsToTicks(sec) argument 88 #define OS_Sleep(sec) OS_MSleep((sec) * OS_MSEC_PER_SEC) argument 89 #define OS_SSleep(sec) OS_Sleep(sec) argument
|
| /bsp/allwinner/libraries/sunxi-hal/include/hal/sdmmc/osal/RT-Thread/ |
| A D | _os_time.h | 71 #define OS_SecsToTicks(sec) ((OS_Time_t)(sec) * OS_HZ) argument 82 #define OS_SecsToJiffies(sec) OS_SecsToTicks(sec) argument 91 #define OS_Sleep(sec) OS_MSleep((sec) * OS_MSEC_PER_SEC) argument 92 #define OS_SSleep(sec) OS_Sleep(sec) argument
|
| /bsp/raspberry-pico/Drivers/ |
| A D | drv_rtc.c | 33 tm_new.tm_sec = t.sec; in pico_rtc_get_timeval() 51 t.sec = 0 ; in pico_rtc_init() 63 static rt_err_t pico_rtc_get_secs(time_t *sec) in pico_rtc_get_secs() argument 68 *(time_t *) sec = tv.tv_sec; in pico_rtc_get_secs() 69 LOG_D("RTC: get rtc_time %d", *sec); in pico_rtc_get_secs() 74 static rt_err_t pico_rtc_set_secs(time_t *sec) in pico_rtc_set_secs() argument 80 gmtime_r(sec, &tm); in pico_rtc_set_secs() 82 t.sec = tm.tm_sec ; in pico_rtc_set_secs()
|
| /bsp/wch/risc-v/Libraries/ch32_drivers/ |
| A D | drv_rtc.c | 72 static rt_err_t ch32_get_secs(time_t *sec) in ch32_get_secs() argument 74 *(rt_uint32_t *)sec = RTC_GetCounter(); in ch32_get_secs() 75 LOG_D("RTC: get rtc_time %x\n", *(rt_uint32_t *)sec); in ch32_get_secs() 80 static rt_err_t ch32_set_secs(time_t *sec) in ch32_set_secs() argument 83 RTC_SetCounter(*(rt_uint32_t *)sec); in ch32_set_secs() 88 LOG_D("RTC: set rtc_time %x\n", *(rt_uint32_t *)sec); in ch32_set_secs()
|
| /bsp/k230/drivers/interdrv/wdt/ |
| A D | drv_wdt.c | 80 tout.sec = tops[i] / wdt_clk; in k230_wdt_timeouts_init() 83 tout.msec = msec - (rt_uint64_t)tout.sec * (rt_uint64_t)1000L; in k230_wdt_timeouts_init() 88 if (tout.sec > dst->sec || (tout.sec == dst->sec && in k230_wdt_timeouts_init() 135 if (timeouts[i].sec >= time) in k230_wdt_set_timeout() 162 *((rt_uint64_t *)timeout) = timeouts[i].sec * rmod; in k230_wdt_get_timeout() 185 if (!timeouts[KD_WDT_NUM_TOPS - 1].sec) in k230_wdt_init()
|
| /bsp/hc32/tests/ |
| A D | test_hwtimer.c | 114 timeout_s.sec = atoi(argv[3]) / 1000U; /* 秒 */ in hwtimer_sample() 144 overflow_tv.sec = (rt_int32_t)t; in hwtimer_sample() 145 overflow_tv.usec = (rt_int32_t)((t - overflow_tv.sec) * 1000000); in hwtimer_sample() 147 timeout_s.sec = overflow_tv.sec + (timeout_s.usec + overflow_tv.usec) / 1000000; in hwtimer_sample() 150 rt_kprintf("Read: Sec = %d, Usec = %d\n", timeout_s.sec, timeout_s.usec); in hwtimer_sample()
|
| /bsp/k230/drivers/utest/ |
| A D | test_timer.c | 99 timerval.sec = TIMEOUT_SEC_0; in test_hwtimer() 107 LOG_I("timer0 start: [%d:%d]\n", timerval.sec, timerval.usec); in test_hwtimer() 109 timerval.sec = TIMEOUT_SEC_1; in test_hwtimer() 117 LOG_I("timer1 start: [%d:%d]\n", timerval.sec, timerval.usec); in test_hwtimer() 123 LOG_I("timer0: [%d:%d]\n", timerval.sec, timerval.usec); in test_hwtimer() 127 LOG_I("timer1: [%d:%d]\n", timerval.sec, timerval.usec); in test_hwtimer()
|
| /bsp/hpmicro/libraries/hpm_sdk/drivers/inc/ |
| A D | hpm_ptpc_drv.h | 140 static inline void ptpc_set_second_update(PTPC_Type *ptr, uint8_t index, uint32_t sec) in ptpc_set_second_update() argument 142 ptr->PTPC[index].TS_UPDTH = PTPC_PTPC_TS_UPDTH_SEC_UPDATE_SET(sec); in ptpc_set_second_update() 191 static inline void ptpc_config_compare(PTPC_Type *ptr, uint8_t index, uint32_t sec, uint32_t ns) in ptpc_config_compare() argument 193 ptr->PTPC[index].TARH = PTPC_PTPC_TARH_TARGET_TIME_HIGH_SET(sec); in ptpc_config_compare() 205 static inline void ptpc_update_timestamp_second(PTPC_Type *ptr, uint8_t index, uint32_t sec) in ptpc_update_timestamp_second() argument 207 ptr->PTPC[index].TS_UPDTH = PTPC_PTPC_TS_UPDTH_SEC_UPDATE_SET(sec); in ptpc_update_timestamp_second() 380 hpm_stat_t ptpc_init_timer_with_initial(PTPC_Type *ptr, uint8_t index, uint32_t sec, uint32_t ns, p… 392 hpm_stat_t ptpc_update_timer(PTPC_Type *ptr, uint8_t index, uint32_t sec, uint32_t ns, ptpc_countin…
|
| /bsp/acm32/acm32f0x0-nucleo/drivers/ |
| A D | drv_wdt.c | 47 rt_inline rt_base_t calc_wdt_divisor_load(rt_uint32_t freq, rt_uint32_t sec, rt_uint32_t *divisor, … in calc_wdt_divisor_load() argument 56 if (sec < freqMaxSec) in calc_wdt_divisor_load() 70 *load = sec * (freq >> minFreqDiv); in calc_wdt_divisor_load() 74 rt_inline rt_base_t calc_iwdt_divisor_load(rt_uint32_t freq, rt_uint32_t sec, rt_uint32_t *divisor,… in calc_iwdt_divisor_load() argument 83 if (sec * 1000 < freqMaxMs) in calc_iwdt_divisor_load() 97 if (sec < 1000) in calc_iwdt_divisor_load() 99 *load = (sec * 1000) * IWDT_RELOAD_MAX_VALUE / freqMaxMs; in calc_iwdt_divisor_load() 103 *load = (sec) * IWDT_RELOAD_MAX_VALUE / freqMaxMs / 1000; in calc_iwdt_divisor_load()
|
| /bsp/maxim/libraries/MAX32660PeriphDriver/Source/ |
| A D | rtc.c | 203 int RTC_Init(mxc_rtc_regs_t *rtc, uint32_t sec, uint8_t ssec, sys_cfg_rtc_t *sys_cfg) in RTC_Init() argument 235 rtc->sec = sec; in RTC_Init() 377 return MXC_RTC->sec; in RTC_GetSecond() 381 int RTC_GetTime(uint32_t* sec, uint32_t* subsec) in RTC_GetTime() argument 407 *sec = RTC_GetSecond(); in RTC_GetTime() 410 } while (temp_sec != *sec); in RTC_GetTime()
|
| /bsp/Infineon/libraries/HAL_Drivers/ |
| A D | drv_rtc.c | 124 static rt_err_t _rtc_get_secs(time_t *sec) in _rtc_get_secs() argument 129 *(time_t *) sec = tv.tv_sec; in _rtc_get_secs() 130 LOG_D("RTC: get rtc_time %d", *sec); in _rtc_get_secs() 135 static rt_err_t _rtc_set_secs(time_t *sec) in _rtc_set_secs() argument 139 if (set_rtc_time_stamp(*sec)) in _rtc_set_secs() 144 LOG_D("RTC: set rtc_time %d", *sec); in _rtc_set_secs()
|
| /bsp/n32/libraries/n32_drivers/ |
| A D | drv_rtc.c | 207 static rt_err_t n32_rtc_get_secs(time_t *sec) in n32_rtc_get_secs() argument 212 *(time_t *) sec = tv.tv_sec; in n32_rtc_get_secs() 214 rt_kprintf("RTC: get rtc_time %d.\n", *sec); in n32_rtc_get_secs() 219 static rt_err_t n32_rtc_set_secs(time_t *sec) in n32_rtc_set_secs() argument 223 if (set_rtc_time_stamp(*sec)) in n32_rtc_set_secs() 228 rt_kprintf("RTC: set rtc_time %d.\n", *sec); in n32_rtc_set_secs()
|
| /bsp/renesas/libraries/HAL_Drivers/ |
| A D | drv_rtc.c | 76 static rt_err_t ra_get_secs(time_t *sec) in ra_get_secs() argument 78 *(rt_uint32_t *)sec = get_rtc_timestamp(); in ra_get_secs() 79 LOG_D("RTC: get rtc_time %x\n", *(rt_uint32_t *)sec); in ra_get_secs() 112 static rt_err_t ra_set_secs(time_t *sec) in ra_set_secs() argument 117 if (set_rtc_time_stamp(*(rt_uint32_t *)sec)) in ra_set_secs() 121 LOG_D("RTC: set rtc_time %x\n", *(rt_uint32_t *)sec); in ra_set_secs()
|
| /bsp/hpmicro/libraries/hpm_sdk/drivers/src/ |
| A D | hpm_ptpc_drv.c | 70 hpm_stat_t ptpc_update_timer(PTPC_Type *ptr, uint8_t index, uint32_t sec, uint32_t ns, ptpc_countin… in ptpc_update_timer() argument 75 ptpc_set_second_update(ptr, index, sec); in ptpc_update_timer() 87 hpm_stat_t ptpc_init_timer_with_initial(PTPC_Type *ptr, uint8_t index, uint32_t sec, uint32_t ns, p… in ptpc_init_timer_with_initial() argument 92 ptpc_set_second_update(ptr, index, sec); in ptpc_init_timer_with_initial()
|
| /bsp/hc32/libraries/hc32_drivers/ |
| A D | drv_rtc.c | 264 static rt_err_t _rtc_get_secs(time_t *sec) in _rtc_get_secs() argument 269 *(time_t *) sec = tv.tv_sec; in _rtc_get_secs() 270 LOG_D("RTC: get rtc_time %d", *sec); in _rtc_get_secs() 275 static rt_err_t _rtc_set_secs(time_t *sec) in _rtc_set_secs() argument 279 if (hc32_rtc_set_time_stamp(*sec)) in _rtc_set_secs() 283 LOG_D("RTC: set rtc_time %d", *sec); in _rtc_set_secs()
|
| /bsp/apm32/libraries/Drivers/ |
| A D | drv_rtc.c | 136 static rt_err_t apm32_rtc_get_secs(time_t *sec) in apm32_rtc_get_secs() argument 148 *(time_t *) sec = RTC_ReadCounter(); in apm32_rtc_get_secs() 153 static rt_err_t apm32_rtc_set_secs(time_t *sec) in apm32_rtc_set_secs() argument 170 RTC_ConfigCounter(*(rt_uint32_t *)sec); in apm32_rtc_set_secs()
|
| /bsp/phytium/libraries/port/fdriver_port/ |
| A D | fdrivers_port.c | 72 void FDriverSdelay(u32 sec) in FDriverSdelay() argument 74 u32 msec = sec * 1000; in FDriverSdelay()
|
| /bsp/stm32/libraries/HAL_Drivers/drivers/ |
| A D | drv_rtc.c | 280 static rt_err_t stm32_rtc_get_secs(time_t *sec) in stm32_rtc_get_secs() argument 285 *(time_t *) sec = tv.tv_sec; in stm32_rtc_get_secs() 286 LOG_D("RTC: get rtc_time %d", *sec); in stm32_rtc_get_secs() 291 static rt_err_t stm32_rtc_set_secs(time_t *sec) in stm32_rtc_set_secs() argument 295 if (set_rtc_time_stamp(*sec)) in stm32_rtc_set_secs() 299 LOG_D("RTC: set rtc_time %d", *sec); in stm32_rtc_set_secs()
|
| /bsp/maxim/libraries/MAX32660PeriphDriver/Include/ |
| A D | rtc.h | 165 int RTC_Init(mxc_rtc_regs_t *rtc, uint32_t sec, uint8_t ssec, sys_cfg_rtc_t *sys_cfg); 230 int RTC_GetTime(uint32_t* sec, uint32_t* subsec);
|
| /bsp/bouffalo_lab/libraries/rt_drivers/sample/ |
| A D | hwtimer_sample.c | 72 timeout_s.sec = 2; /* 秒 */ in hwtimer_sample() 85 rt_kprintf("Read: Sec = %d, Usec = %d\n", timeout_s.sec, timeout_s.usec); in hwtimer_sample()
|
| /bsp/nxp/imx/imx6ull-smart/drivers/usb/include/ |
| A D | usb_misc.h | 318 #define USB_LINK_SECTION_SUB(sec) USB_LINK_SECTION_PART(location = #sec) argument 331 #define USB_LINK_SECTION_SUB(sec) __attribute__((section(#sec))) 344 #define USB_LINK_SECTION_SUB(sec) __attribute__((section(#sec)))
|
| /bsp/raspberry-pi/raspi3-32/applications/ |
| A D | test_device.c | 269 val.sec = t; in test_hwtimer() 271 rt_kprintf("SetTime: Sec %d, Usec %d\n", val.sec, val.usec); in test_hwtimer() 284 rt_kprintf("Read: Sec = %d, Usec = %d\n", val.sec, val.usec); in test_hwtimer() 291 val.sec = t; in test_hwtimer() 293 rt_kprintf("SetTime: Sec %d, Usec %d\n", val.sec, val.usec); in test_hwtimer()
|
| /bsp/bluetrum/libraries/hal_drivers/ |
| A D | drv_rtc.c | 125 time_t sec = 0; in hal_rtc_init() local 137 sec = timegm(&tm_new); in hal_rtc_init() 139 irtc_time_write(RTCCNT_CMD, sec); in hal_rtc_init()
|