Experimental Physics and Industrial Control System
|
Hi Marco,
I don't know if there's a native functionality for this, but for some of our IOCs we use python to do some of these things. You can add something like "system 'python3 iocApp/py/script.py arguments
&'" to the startup script. The script would do a camonitor ' MYRECORD:Output' and have a callback to read the file and do the respective actions. It's not as clean as your original proposition, but it should be faster to get
running until you figure something a better solution.
Pedro Nariyoshi
Software Controls Engineer
Facility for Rare Isotope Beams
Michigan State University
640 South Shaw Lane
East Lansing, MI 48824, USA
Tel. 517-908-7352
Email: nariyosh at frib.msu.edu
|
![1633986722804](jpgmlD4owJJFe.jpg)
|
From: Marco A. Barra Montevechi Filho <marco.filho at lnls.br>
Sent: Thursday, November 24, 2022 10:02 AM
To: tech-talk at aps.anl.gov
Subject: How to: IOC reading information from file?
[EXTERNAL] This email originated from outside of FRIB
Hello all.
I want to create a set of configuration files (probably json, yaml or even txt) that i can make my IOC read and put the values into PVs. I could swear i read something about reading configuration files in EPICS documentation before but i cant for the life of
me find it again.
Desired functionality would be something like:
file config0.yaml has: {"my_var" : 0}
file config1.yaml has: {"my_var" : 1}
And then i would have a record, say MYRECORD:Output that when i do:
caput MYRECORD:Output "config0.yaml"
the record would output 0 to its output link. And
caput MYRECORD:Output "config1.yaml"
the record would output 1 to its output link.
Is there any module or record that offers similar functionality?
Thanks in advance,
Marco
Aviso Legal: Esta mensagem e seus anexos podem conter informações confidenciais e/ou de uso restrito. Observe atentamente seu conteúdo e considere eventual consulta
ao remetente antes de copiá-la, divulgá-la ou distribuí-la. Se você recebeu esta mensagem por engano, por favor avise o remetente e apague-a imediatamente.
Disclaimer: This email and its attachments may contain confidential and/or privileged information. Observe its content carefully and consider possible querying
to the sender before copying, disclosing or distributing it. If you have received this email by mistake, please notify the sender and delete it immediately.
|
- Replies:
- Re: How to: IOC reading information from file? Marco A. Barra Montevechi Filho via Tech-talk
- References:
- How to: IOC reading information from file? Marco A. Barra Montevechi Filho via Tech-talk
- Navigate by Date:
- Prev:
manage-procs and conserver: use cases? Kuldeep Joshi via Tech-talk
- Next:
Re: Illegal field value PV: oms:m1 motor_init_record_com(): card does not exist! motorOMS st.cmd error Kevin Peterson 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
- Navigate by Thread:
- Prev:
How to: IOC reading information from file? Marco A. Barra Montevechi Filho via Tech-talk
- Next:
Re: How to: IOC reading information from file? Marco A. Barra Montevechi Filho 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
|
ANJ, 28 Nov 2022 |
·
Home
·
News
·
About
·
Base
·
Modules
·
Extensions
·
Distributions
·
Download
·
·
Search
·
EPICS V4
·
IRMIS
·
Talk
·
Bugs
·
Documents
·
Links
·
Licensing
·
|