1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 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 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 <2023> 2024 |
<== Date ==> | <== Thread ==> |
---|
Subject: | Re: More precise timing for record processing |
From: | "Arnold, Ned D. via Tech-talk" <tech-talk at aps.anl.gov> |
To: | "tech-talk at aps.anl.gov" <tech-talk at aps.anl.gov>, "Sobhani, Alex" <sobhaniba at ornl.gov> |
Date: | Tue, 30 May 2023 13:45:08 +0000 |
Alex -
You can use the delay field in a sequence record to create specific scan frequencies ... like that shown below. Change TestRecord1.DLY1 to the period you want it to scan. If multiple records need to be processed at this rate, TestRecord2 could become an event
record that posts a soft event which causes other records to scan.
Ned
record(seq,TestRecord1) {
field(PINI,"1")
field(DLY1,"3")
field(LNK1,"TestRecord2.PROC CP NMS")
field(LNK2,"TestRecord1 CP NMS")
}
record(calcout,"TestRecord2") {
field(INPA,"TestRecord2.VAL NPP NMS")
field(CALC,"A+1")
}From: Tech-talk <tech-talk-bounces at aps.anl.gov> on behalf of Sobhani, Alex via Tech-talk <tech-talk at aps.anl.gov>
Sent: Sunday, May 28, 2023 08:35 PM To: tech-talk at aps.anl.gov <tech-talk at aps.anl.gov> Subject: More precise timing for record processing The SCAN field lets you choose from .1, .2, .5, 1, 2, 5, or 10 seconds. In cases where this is not enough, is there a simple way to make a record process at other intervals such as 2.7 seconds or 5.4 seconds, specified at runtime? I know you can add options for more periods of the SCAN field by editing dbd files, but you cannot change your mind at runtime.
I envision something like this:
record(timer, “BL0:mytimer”){ field(PERI, 2.7) field(FLNK, “BL0:mytrigger”) }
And then subfields to enable/disable it.
Does anything like this exist? I would imagine that something like this would be very generally useful.
Alex |