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  2022  <20232024  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  <20232024 
<== Date ==> <== Thread ==>

Subject: Re: Phoebus/CS-Studio widget question
From: "Kasemir, Kay via Tech-talk" <tech-talk at aps.anl.gov>
To: "David A. Slimmer" <slimmer at fnal.gov>, "tech-talk at aps.anl.gov" <tech-talk at aps.anl.gov>
Cc: "David A. Slimmer" <slimmer at fnal.gov>
Date: Fri, 9 Jun 2023 14:31:23 +0000

> I’m creating a display for my ioc which has an array of OR’d error bit values. I’m trying to decode those bits on my display using an array of Byte Monitor (leds).

> For the display to decode the bits correctly though, the Byte Monitor would have to display in hex rather than in binary. Is there a way to do that, or do I just have to use some other approach?

 

If you have a value that’s now a plain number like a pressure reading but a collection of bits where the different bits mean different things, you can decode that on the IOC by using mbbiDirect records that split each bit out, which is good for individual bits, or by using mbbi records that map bit patterns to distinct states.

The end result are then new PVs with distinct meaning.

 

 

Otherwise, you can do some decoding in the display:

 

The Text Update widget can display with Format=Hex and Precision for example set to 8 so you get “0x12345670”.

The LED widget has a “bit” property to have it indicate just one bit of the value.

The ByteMonitor widget can display for example 32 bits and show a label for each bit. That is useful for a basic “Status Register” display where each bit means something, but you likely still want an mbbiDirect on your IOC so you can then create logic on the IOC that does something when for example some “Fault bit” is set.

 

-Kay

 


References:
Phoebus/CS-Studio widget question David A. Slimmer via Tech-talk

Navigate by Date:
Prev: Phoebus/CS-Studio widget question David A. Slimmer via Tech-talk
Next: Optional record alias 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  2021  2022  <20232024 
Navigate by Thread:
Prev: Phoebus/CS-Studio widget question David A. Slimmer via Tech-talk
Next: Optional record alias 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  2021  2022  <20232024 
ANJ, 11 Jun 2023 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·