FireBirdLib - Topfield TMS PVR TAP Programming Library
GetCurrentTimeZone.c
Go to the documentation of this file.
1
#include "
FBLib_time.h
"
2
3
bool
GetCurrentTimeZone
(
short
*TZOffset,
bool
*DST)
4
{
5
TRACEENTER
();
6
7
//TZOffset receives the offset in minutes in the standard time zone
8
//DST is set to TRUE if the Toppy is currently in DST mode
9
10
tFlashTimeInfo
FlashTimeInfo;
11
bool
ret;
12
13
ret = FALSE;
14
if
(
FlashTimeGetInfo
(&FlashTimeInfo))
15
{
16
if
(TZOffset)
17
{
18
*TZOffset = FlashTimeInfo.
UTCOffset
;
19
if
(FlashTimeInfo.
DSTActive
) *TZOffset =
AddTime
(*TZOffset, -60);
20
}
21
22
if
(DST) *DST = FlashTimeInfo.
DSTActive
;
23
24
ret = TRUE;
25
}
26
27
TRACEEXIT
();
28
return
ret;
29
}
FBLib_time.h
FlashTimeGetInfo
bool FlashTimeGetInfo(tFlashTimeInfo *TimeInfo)
Definition:
FlashTimeDecode.c:87
GetCurrentTimeZone
bool GetCurrentTimeZone(short *TZOffset, bool *DST)
Definition:
GetCurrentTimeZone.c:3
AddTime
dword AddTime(dword pvrDate, int addMinutes)
Definition:
AddTime.c:3
TRACEEXIT
#define TRACEEXIT()
Definition:
libFireBird.h:1244
TRACEENTER
#define TRACEENTER()
Definition:
libFireBird.h:1243
tFlashTimeInfo
Definition:
libFireBird.h:1639
tFlashTimeInfo::UTCOffset
short UTCOffset
Definition:
libFireBird.h:1640
tFlashTimeInfo::DSTActive
word DSTActive
Definition:
libFireBird.h:1650
time
GetCurrentTimeZone.c
Generated on Fri Apr 29 2022 13:34:01 for FireBirdLib - Topfield TMS PVR TAP Programming Library by
1.9.3