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  <20222023  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  2021  <20222023  2024 
<== Date ==> <== Thread ==>

Subject: Re: [EXTERNAL] PVXS and Phoebus
From: "Kasemir, Kay via Tech-talk" <tech-talk at aps.anl.gov>
To: "tech-talk at aps.anl.gov" <tech-talk at aps.anl.gov>, Florian Feldbauer <florian at ep1.ruhr-uni-bochum.de>
Date: Mon, 10 Oct 2022 14:57:04 +0000
"Boolean" PVs like those created by bi, bo records don't serve "boolean" data as one might expect.
They instead serve enumerated data like this:

epics:nt/NTEnum:1.0
    enum_t value (0) OK
        int index 0
        string[] choices [OK, Error]

Phoebus as a generic operator interface/client decodes the types provided by the IOC.
It's not prepared to handle any arbitrary data that custom clients might generate.

Having said that, I think it's a good idea to be more lenient and also support "boolean" data, even if no IOC at this time will generate it, so  I've added that to the list: https://github.com/ControlSystemStudio/phoebus/issues/2410

-Kay



From: Tech-talk <tech-talk-bounces at aps.anl.gov> on behalf of Florian Feldbauer via Tech-talk <tech-talk at aps.anl.gov>
Sent: Wednesday, October 5, 2022 10:40 AM
To: tech-talk at aps.anl.gov <tech-talk at aps.anl.gov>
Subject: [EXTERNAL] PVXS and Phoebus
 
Hey all,

I have written a small program using the PVXS library. Trying to access
the PVs with Phoebus release 4.7.0 I encountered an issues:

I'm using a boolean button widget in Phoebus to access a NTScalar with
boolean type and get the message "Cannot decode ..."

In the shell I get the message:

2022-10-05 16:24:10 WARNING [org.phoebus.pv] Cannot decode
'PND:LMD:RUNCTRL:SHUTDOWN' [CID 2, SID 117768961 CONNECTED] =
epics:nt/NTScalar:1.0
     boolean value false
     alarm_t alarm [NO_ALARM]
         int severity 0
         int status 0
         string message
     time_t timeStamp [2022-10-05 16:23:26.000318114]
         long secondsPastEpoch 1664979806
         int nanoseconds 318114
         int userTag 0
java.lang.Exception: Expected struct with scalar 'value', got
epics:nt/NTScalar:1.0
     boolean value false
     alarm_t alarm [NO_ALARM]
         int severity 0
         int status 0
         string message
     time_t timeStamp [2022-10-05 16:23:26.000318114]
         long secondsPastEpoch 1664979806
         int nanoseconds 318114
         int userTag 0
     at
org.phoebus.pv.pva.PVAStructureHelper.decodeScalar(PVAStructureHelper.java:148)
     at
org.phoebus.pv.pva.PVAStructureHelper.getVType(PVAStructureHelper.java:99)
     at org.phoebus.pv.pva.PVA_PV.handleMonitor(PVA_PV.java:88)
     at
org.epics.pva.client.MonitorRequest.decodeValueUpdate(MonitorRequest.java:236)
     at
org.epics.pva.client.MonitorRequest.handleResponse(MonitorRequest.java:198)
     at
org.epics.pva.client.MonitorHandler.handleCommand(MonitorHandler.java:40)
     at
org.epics.pva.client.MonitorHandler.handleCommand(MonitorHandler.java:21)
     at
org.epics.pva.common.CommandHandlers.handleCommand(CommandHandlers.java:66)
     at
org.epics.pva.client.ClientTCPHandler.handleApplicationMessage(ClientTCPHandler.java:331)
     at org.epics.pva.common.TCPHandler.handleMessage(TCPHandler.java:394)
     at org.epics.pva.common.TCPHandler.receiver(TCPHandler.java:294)
     at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
     at
java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
     at
java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
     at java.base/java.lang.Thread.run(Thread.java:833)

Is the boolean type not implemented in Phoebus? In that case I would
switch to an int value.


Cheers,
Florian


--
Ruhr-Universität Bochum
AG der Experimentalphysik I
Dr. Florian Feldbauer
NB 2/131 / Fach 125
Universitätsstr. 150
D-44801 Bochum

Office: NB 2/134
Phone:  (+49)234 / 32-23563
Fax:    (+49)234 / 32-14170
https://paluma.ruhr-uni-bochum.de


Replies:
Re: [EXTERNAL] PVXS and Phoebus Florian Feldbauer via Tech-talk
References:
PVXS and Phoebus Florian Feldbauer via Tech-talk

Navigate by Date:
Prev: Re: Phoebus zoom etc toolbar Steve Kinder - STFC UKRI via Tech-talk
Next: Re: Phoebus zoom etc toolbar Kasemir, Kay 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  <20222023  2024 
Navigate by Thread:
Prev: PVXS and Phoebus Florian Feldbauer via Tech-talk
Next: Re: [EXTERNAL] PVXS and Phoebus Florian Feldbauer 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  <20222023  2024 
ANJ, 11 Oct 2022 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·