SysTimeRtcGetTimezone (FUN)

FUNCTION SysTimeRtcGetTimezone : RTS_IEC_RESULT

<description>Returns the timezone information.

The existing platform implementations of SysTimeRtcGetTimezone() differ from the specification in the following ways. These will not be changed for compatibility reasons. Use the SysTimeRtcGetTimezone2() function instead.

Windows: The conversions of “TimezoneInformation.ulStandardDate” and “TimezoneInformation.ulDaylightDate” to RTS_SYSTIMEDATE produce the following incorrect results:

  • RTS_SYSTIMEDATE.wYear contains the current year (expected value: 0).

  • RTS_SYSTIMEDATE.wDayOfWeek contains an incorrect day of the week depending on the year (expected value: 7).

Linux:

“TimezoneInformation.ulStandardDate” is 0 (expected value: Date and local time when the transition from daylight saving time to standard time occurs on this device). “TimezoneInformation.ulDaylightDate” is 0 (expected value: Date and local time when the transition from standard time to daylight saving time occurs on this device).

“TimezoneInformation.iBias” contains the negative bias, i.e. the expected value multiplied with -1. “TimezoneInformation.iDaylightBias” is 0 (expected value: The bias value to be used during local time translations that occur during daylight saving time. In most time zones, the value of this member is -60.).

VxWorks (tested on VxWorks 7.1 ARM Beagle Bone Black):

“TimezoneInformation.ulStandardDate” is 0 (expected value: Date and local time when the transition from daylight saving time to standard time occurs on this device). “TimezoneInformation.ulDaylightDate” is 0 (expected value: Date and local time when the transition from standard time to daylight saving time occurs on this device).

“TimezoneInformation.iDaylightBias” is 0 (expected value: The bias value to be used during local time translations that occur during daylight saving time. In most time zones, the value of this member is -60.). (“TimezoneInformation.iBias” contains the expected value.)

DEPRECATED: As of release 3.5.20.0, replaced by SysTimeRtcGetTimezone2().

</description> <result><p>RESULT: Returns the runtime system error code (see CmpErrors.library).</p></result>

InOut:

Scope

Name

Type

Comment

Return

SysTimeRtcGetTimezone

RTS_IEC_RESULT

Inout

pTimezone

TimezoneInformation

<param name=”pTimezone” type=”OUT”>Pointer to timezone information. See corresponding category.</param>