EPICS Home

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  2014  2015  2016  <20172018  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  2014  2015  2016  <20172018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: Re: Reset integral pv and store it
From: Ralph Lange <[email protected]>
To: EPICS Tech Talk <[email protected]>
Date: Sat, 1 Apr 2017 14:08:28 +0200
The core functionality would look like this:

record(stringin,"clock") {
  field(DTYP,"Soft Timestamp")
  field(INP,"@%H%M%S")
  field(SCAN,"5 second")
  field(FLNK,"check")
}
record(calcout,"check") {
  field(INPA,"clock")
  field(CALC,"A>235950?1:0")
  field(OOPT,"Transition To Zero")
  field(OUT,"do_reset PP")
}
record(seq,"do_reset") {
# do all the steps to reset the integral here
}

All background information is in the Record Reference Manual:
https://wiki-ext.aps.anl.gov/epics/index.php/RRM_3-14

Good luck!
~Ralph



On Sat, Apr 1, 2017 at 12:42 PM, Miguel <[email protected]> wrote:
On March 31, 2017 4:47:43 PM GMT+02:00, Miguel <[email protected]> wrote:
I would like at the end of the day(certain timestamp) ..

On Mar 31, 2017, at 2:21 PM, Ralph Lange <[email protected]> wrote:
Yet another idea:
The stringin record has support for strftime formats. If you use that to create a six digit hhmmss number, you can use a calcout record to e.g. check for <10 and process a seq record on the 1->0 edge to do the integral reset sequence.
That’s a brilliant way to get the local time, without calling out to C code (subroutine rec, SNL), as a number!

Yes, do that. Disregard everything else I wrote.

-Kay


Guys thanks a lot for your suggestions

But would you mind to be more specific on how can i do it? I am quite new to EPICS and i am not really into this subjects yet.

-MiguelB


References:
Re: Reset integral pv and store it Miguel

Navigate by Date:
Prev: Re: Reset integral pv and store it Miguel
Next: stringout in softIOC Al Honey
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  <20172018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: Re: Reset integral pv and store it Miguel
Next: stringout in softIOC Al Honey
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  <20172018  2019  2020  2021  2022  2023  2024