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  <20212022  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  <20212022  2023  2024 
<== Date ==> <== Thread ==>

Subject: Referencing PV values in commands from Action Buttons in CS-Studio.
From: "Li, Ji via Tech-talk" <tech-talk at aps.anl.gov>
To: "tech-talk at aps.anl.gov" <tech-talk at aps.anl.gov>
Date: Mon, 17 May 2021 19:25:12 +0000
Hi,

I'm wondering if it's possible to execute a command with a PV's value as a parameter. For example, to open the IP address defined by a PV (device:ipaddr, stringin) in a browser.

I tried command:

firefox $(device:ipaddr)

The browser was directed to http://www.$(device:ipaddr).com/

I tried command:

firefox `caget device:ipaddr | awk '{print $2}'`

It works in shell, but in CS-Studio it jumps to http://www.`caget.com/

What works for me now is to run the command in python script, but it's kind of cumbersome. Are there better ways to implement? Thanks.

Best,

-Ji Li


Navigate by Date:
Prev: RE: Means of comparing alarm status with a conditional in a CALC record Wang, Andrew via Tech-talk
Next: Re: Utilizing StreamDevice in conjunction with sockets Mark Rivers 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  <20212022  2023  2024 
Navigate by Thread:
Prev: RE: Utilizing StreamDevice in conjunction with sockets Mark Rivers via Tech-talk
Next: Archiver Appliance mgmt tomcat issue Manoussakis, Adamandios 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  <20212022  2023  2024 
ANJ, 18 May 2021 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·