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

Subject: Re: spread database processing over a time interval
From: "Johnson, Andrew N. via Tech-talk" <tech-talk at aps.anl.gov>
To: Majer Karel <karel.majer at eli-laser.eu>, "tech-talk at aps.anl.gov" <tech-talk at aps.anl.gov>
Date: Mon, 24 Aug 2026 22:25:40 +0000
Hi Karel,

One approach you might look at uses the Event​ scan type and the record EVNT​ fields which hold event names.

You can write your own C/C++ code that periodically calls postEvent(evnt);​ where the EVENTPVT evnt​ was returned by a call to eventNameToHandle(char *name)​ and that name​ string matches the EVNT​ fields of one or more records. Posting an event like that causes all of the records whose EVNT​ values match to be processed by one of the IOC’s callback tasks. You can create as many of these as you like (within memory limits) so you can spread them around in time as you need.

The IOC shell command scanpel​ is useful to see what event names your IOC knows, or list which records will be scanned by a particular event name that you provide (recent versions of Base even accept a pattern for matching name).

HTH,

- Andrew

-- 
Complexity comes for free, Simplicity you have to work for.


On 8/24/26, 3:37 PM, "Tech-talk" <tech-talk-bounces at aps.anl.gov> wrote:

Hi,

I have a slightly weird question and Claude suggested it's not possible, but I'll still ask.

I'm writing device support for Ekspla laser units. They have several hundred registers which are published as individual HTML pages, reading all of them usually takes several seconds. The device support is a subclass of AsynPortDriver.

I want to read some of the registers once per second, while many others may be read only once per minute. But it occured to me, that when the scan thread schedules processing of the bulk of the records, my once-per-second registers will be delayed probably by more than a seconds, which is undesirable. I was looking for a mechanism to spread processing of the slow records over the minute interval or to somehow process the fast records with higher priority, but didn't find anything suitable.

Does EPICS base or asyn driver provide a mechanism for this? I mean something nicer than using a sequence record.

Thanks,
Karel

Karel Majer | Controls Software Development Group Leader
Phone: +420 607 205 469
E-mail: karel.majer
@eli-laser.eu


ELI Beamlines Facility|The Extreme Light Infrastructure ERIC
Za Radnicí 835, 252 41 Dolní Břežany, The Czech Republic
www.eli-laser.eu 


Replies:
Re: spread database processing over a time interval Sukhanov, Andrei via Tech-talk
References:
spread database processing over a time interval Majer Karel via Tech-talk

Navigate by Date:
Prev: spread database processing over a time interval Majer Karel via Tech-talk
Next: Re: spread database processing over a time interval Sukhanov, Andrei via Tech-talk
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  2025  <2026> 
Navigate by Thread:
Prev: spread database processing over a time interval Majer Karel via Tech-talk
Next: Re: spread database processing over a time interval Sukhanov, Andrei via Tech-talk
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  2025  <2026> 
ANJ, 24 Aug 2026 · Home · News · About · Talk · Base · Modules · Extensions ·
· Distributions · Download · Documents · Links · Licensing ·