Mistake on this page? Email us
pal_time.h
Go to the documentation of this file.
1 // ----------------------------------------------------------------------------
2 // Copyright 2016-2019 ARM Ltd.
3 //
4 // SPDX-License-Identifier: Apache-2.0
5 //
6 // Licensed under the Apache License, Version 2.0 (the "License");
7 // you may not use this file except in compliance with the License.
8 // You may obtain a copy of the License at
9 //
10 // http://www.apache.org/licenses/LICENSE-2.0
11 //
12 // Unless required by applicable law or agreed to in writing, software
13 // distributed under the License is distributed on an "AS IS" BASIS,
14 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 // See the License for the specific language governing permissions and
16 // limitations under the License.
17 // ----------------------------------------------------------------------------
18 
19 #ifndef _PAL_TIME_H
20 #define _PAL_TIME_H
21 
22 #ifndef _PAL_H
23  #error "Please do not include this file directly, use pal.h instead"
24 #endif
25 
26 #include <stdint.h>
27 
28 
29 #ifdef __cplusplus
30 extern "C" {
31 #endif
32 
50 
60 uint64_t pal_osGetTime(void);
61 
69 palStatus_t pal_osSetTime(uint64_t seconds);
70 
93 palStatus_t pal_osSetWeakTime(uint64_t setTimeInSeconds);
94 
110 palStatus_t pal_osSetStrongTime(uint64_t setTimeInSeconds);
111 
112 
113 #ifdef __cplusplus
114 }
115 #endif
116 #endif //_PAL_TIME_H
uint64_t pal_osGetTime(void)
Get the system time.
palStatus_t pal_osSetStrongTime(uint64_t setTimeInSeconds)
Set the strong time. This function will be called when receiving time from a server that is completel...
palStatus_t pal_osSetTime(uint64_t seconds)
Set the current system time, defined as seconds since January 1st 1970 UTC+0.
palStatus_t pal_initTime(void)
Initializes the time module.
palStatus_t pal_osSetWeakTime(uint64_t setTimeInSeconds)
Set the weak time.
int32_t palStatus_t
Definition: pal_types.h:55