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 | 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 |
<== Date ==> | <== Thread ==> |
---|
Subject: | Re: Periodically calling shell functions in an IOC |
From: | "Hu, Yong via Tech-talk" <tech-talk at aps.anl.gov> |
To: | Ralph Lange <ralph.lange at gmx.de>, EPICS Tech Talk <tech-talk at aps.anl.gov> |
Date: | Fri, 15 Oct 2021 13:41:34 +0000 |
Hi Andrew W.: If you do not want to hack “streamReload”, you may try this:
https://github.com/NSLS-II/elauncher
It is an EPICS device support for easy script launcher: one can run a Python (or shell, or anything you can use in a Linux terminal) script inside an IOC through a bo record. Michael Davidsaver developed it at NSLS-II a few years ago, specifically
for use cases like yours. You can change how fast you want to execute your script by simply changing the field of SCAN either from a command caput or from a CS-Studio button: caput elauncherTestShell.SCAN 3 caput elauncherTestShell.SCAN Passive caget -d GR_ENUM elauncherTestShell.SCAN elauncherTestShell.SCAN Native data type: DBF_ENUM Request type: DBR_GR_ENUM Element count: 1 Value: 1 second Status: NO_ALARM Severity: NO_ALARM Enums: (10) [ 0] Passive [ 1] Event [ 2] I/O Intr [ 3] 10 second [ 4] 5 second [ 5] 2 second [ 6] 1 second [ 7] .5 second [ 8] .2 second [ 9] .1 second Cheers, Yong From: Tech-talk <tech-talk-bounces at aps.anl.gov> on behalf of "tech-talk at aps.anl.gov" <tech-talk at aps.anl.gov> On Wed, 13 Oct 2021 at 22:45, Wang, Andrew via Tech-talk <tech-talk at aps.anl.gov> wrote:
This is unusual as operating mode. The reload function is intended for development / rapid prototyping (testing a protocol change without rebooting the IOC). So - please be careful with respect to possible side effects: What happens if the protocol file gets corrupted, a typo is being introduced, the disk (or nfs) is down etc. How do you detect such a situation? How do you fix it? Needs testing. Cheers, |