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  2009  2010  2011  2012  2013  <20142015  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  2009  2010  2011  2012  2013  <20142015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: epicsTime::strftime
From: "Pearson, Matthew R." <[email protected]>
To: EPICS core-talk <[email protected]>
Cc: "[email protected] list" <[email protected]>
Date: Tue, 28 Jan 2014 15:15:50 -0500
Hi,

I may have come across a problem with strftime in epicsTime.cpp. I'm finding that it's rounding the fractional seconds part, but not the seconds if the fractional seconds goes to zero. For example:
 
if epicsTime::show() produces:
epicsTime: Tue Jan 28 2014 11:22:53.999977939

the corresponding epicsTime::strftime() produces:
2014-01-28 11:22:53.000

if the format is: "%Y-%m-%d %H:%M:%S.%03f"

Has anyone come across this before?

I'm guessing it's intentional to keep the function relatively simple? 

Cheers,
Matt




Replies:
Re: epicsTime::strftime Andrew Johnson

Navigate by Date:
Prev: Re: PV for both input AND output Matteo Pardi
Next: iocLog Vikram Bhagat
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  <20142015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: RE: EPICS driver for CAEN NIM8304 or N1471 tom.cobb
Next: Re: epicsTime::strftime Andrew Johnson
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  <20142015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 17 Dec 2015 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·