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: error calling PVUtil.getString() |
From: | "Gregory, Ray" <[email protected]> |
To: | "Lang, Keenan C." <[email protected]>, "Engbretson, Mark S." <[email protected]>, "[email protected]" <[email protected]> |
Date: | Mon, 7 May 2018 20:32:36 +0000 |
I am creating the PVs list in the OPI editor in the ‘Attach Scripts’ dialog. For pvs[0] I have defined it to be ‘$(S):INTYPE$(IN_CHN)_S’ in the ‘Input PVs’ tab of the ‘Attach Scripts’ dialog, where S and IN_CHN are macros. Can you please tell me how to print
pvs[0]'s type in the code? Thank you for your help, --Ray From: Lang, Keenan C. <[email protected]> Your error indicates that pvs[0] is a different type of value than the function expects to find.
How are you creating the pvs list? And/or could you print what pvs[0]'s type is right before the command on line 24? From:
[email protected] <[email protected]> on behalf of Gregory, Ray <[email protected]> caget gives: $ caget BL104:SE:LS:INTYPE0_SS BL104:SE:LS:INTYPE0_SS Platinum RTD The PV is a mbbo record. --Ray Ray Gregory Data Acquisition and Controls HFIR Instrument Operations Instrument and Source Division Neutron Sciences Directorate Oak Ridge National Laboratory Building 7964K Room 19 ph (865) 241-1116 cell (417) 827-6515 email:
[email protected] Oak Ridge National Laboratory 1 Bethel Valley Road, MS-6430 Oak Ridge, TN 37830 From: Mark Engbretson <[email protected]>
What is the value of pvs[0] ? From:
[email protected] <[email protected]>
On Behalf Of Gregory, Ray In a CSS BOY OPI I am calling PVUtil.getString() from a script attached to my OPI. I am passing it one of the script’s PV values: Line … 22 from org.csstudio.opibuilder.scriptUtil import PVUtil, ScriptUtil 23 24 sensor_type = PVUtil.getString(pvs[0]) … However I am getting the following error: Traceback (most recent call last): File "scripts/lakeshore_input_setup_monitor.py.py", line 24, in <module> TypeError: getString(): 1st arg can't be coerced to org.csstudio.simplepv.IPV What does this mean? --Ray |