EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  <20092010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  <20092010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: RE: Timezone setting with R3.14.10
From: "Thompson, David H." <[email protected]>
To: Dehong Zhang <[email protected]>, [email protected]
Date: Sun, 04 Jan 2009 14:53:12 -0500
How does the local vxWorks clock get set?
 
Epics time is # seconds since 1/1/1990 00:00:00 UTC and the basic vxWorks clock is from 1/1/70 00:00:00 UTC.  It should be easy to look at the return value from time() and the seconds field in a running record and see if the # seconds there is UTC or CST by just taking that number modulo the # seconds in a day.
 
 
The timezone fields are only used for local time display purposes and would not impact what a camonitor would report.
 
This is what we do:
putenv("EPICS_TS_MIN_WEST=300")

# New DST changes for 2007 Eastern Time Zone US

putenv("EPICS_TIMEZONE=EUS::300:031102:110402")

We also set the local vxWorks clock from NTP at the start, this makes the DST calculation go correctly.  The calls can be made from the startup script.
 

 
________________________________

From: [email protected] on behalf of Dehong Zhang
Sent: Tue 12/30/2008 11:36 AM
To: [email protected]
Subject: Timezone setting with R3.14.10



Hi Everybody, Happy New Year!

Recently we upgraded to 3.14.10 (on vxWorks 6.1).  We are trying to use the time
from the local vxWorks system, instead of the EPICS time/boot server.  So we do
NTPTime_Shutdown
immediately before iocInit.

On the vxWorks console, we can see that the NTP thread is indeed off:

generalTimeReport 1
Backwards time errors prevented 0 times.

Current Time Providers:
    "NTP", priority = 100
        Current Time not available
    "OS Clock", priority = 999
        Current Time is 2008-12-30 10:31:48.890000.

Event Time Providers:
        No Providers registered.
value = 0 = 0x0

Please note: the OS Clock does show the correct local time (US CST).

But on a host machine, if we start a monitor process like "camonitor ..."
we always get the time off by 6 hours.  It seems EPICS takes the CST time
as the GMT time, then convert it back to CST.

We tried both
putenv("TIMEZONE=...
putenv("EPICS_TIMEZONE=

They did not help.

Please advice.

Thanks much and best regards,
Dehong






Replies:
Re: RE: Timezone setting with R3.14.10 Dehong Zhang

Navigate by Date:
Next: EDM Horizontal Bar Szalata, Zenon M.
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  <20092010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Next: Re: RE: Timezone setting with R3.14.10 Dehong Zhang
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  <20092010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 31 Jan 2014 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·