EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

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

Subject: Re: epicsTicksPerSecond for OSI ?
From: Kate Feng <[email protected]>
To: Jeff Hill <[email protected]>, [email protected]
Cc: [email protected]
Date: Tue, 22 Apr 2003 12:05:51 -0400
Hi Jeff,

Jeff Hill wrote:

> Hi Kate,
>
> There are certainly easy ways to compute the difference between
> two EPICS time stamps in seconds and you can also convert an
> EPICS time stamp to an enhanced struct tm (ANSI C) which includes
> the nanoseconds within a second in addition to the conventional
> date, hour, and second fields. For example, the following code
> measures the delay required to do some computationally intensive
> task and also computes the current date and time.
>
> epicsTime begin = epicsTime::getCurrent();
> .
> . something computationally intensive
> .
> // compute the delay
> double delayInSeconds = epicsTime::getCurrent() - begin;
>
> // compute the date
> local_tm_nano_sec localDAteAndTime = epicsTime::getCurrent();
>

Because  you mention this,  I wonder  what is the  finest clock
resolution
of  epicsTimerStartDelay() that I can get.  Can I  employ this technique
to
get  1 ms delay  out of   epicsTimerStartDelay() ?  If so, could you
please
explain further  about the how-to ?

>
> However, perhaps what you are after is thread sleep scheduling
> accuracy? If so, then you may be pleased with the addition of
> "double epicsThreadSleepQuantum(void)" to the epicsThread API in
> the next release of R3.14. This function returns the minimum
> sleep interval obtainable from the local OS and has been very
> useful for improving the accuracy of timers on average.
>

Yes,  epicsThreadSleepQuantum  seems to be exactly what I wanted.
I guess I can get around without it for a while.
However, when  will R3.14.2  be available ?


Many thanks,
Kate






Replies:
RE: epicsTicksPerSecond for OSI ? Jeff Hill
References:
RE: epicsTicksPerSecond for OSI ? Jeff Hill

Navigate by Date:
Prev: RE: epicsTicksPerSecond for OSI ? Jeff Hill
Next: RE: epicsTicksPerSecond for OSI ? Jeff Hill
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  <20032004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: RE: epicsTicksPerSecond for OSI ? Jeff Hill
Next: RE: epicsTicksPerSecond for OSI ? Jeff Hill
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  <20032004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 10 Aug 2010 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·