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

Subject: Numbers as Hex encoded strings in StreamDevice
From: Bo Jakobsen via Tech-talk <tech-talk at aps.anl.gov>
To: "tech-talk at aps.anl.gov" <tech-talk at aps.anl.gov>
Date: Fri, 4 Sep 2020 15:00:20 +0200

Dear all

Sorry if this has been covered before, I could not find an exact example matching my need, and format converts are still a bit hard for me.


I am trying to write a StreamDevice IOC for a display.

The format needed by the display is

cmd(MSB) cmd(LSB) charater(MSB) charater(LSB)

Where values are in hex representation

exampel for a simpel write command (cmd(MSB) cmd(LSB) = FF FE)

FF FE 00 39

which will send the charater "9" ascii 0x39 to the display

Is there a simple way to generate such string representations of numbers from a PV (potentially including scientific representation).


Best

    Bo Jakobsen



-- 
Bo Jakobsen (Physicist, PhD) 
Scientific Engineer / Team leader 

Department of Science and Environment
Roskilde University (RUC)

Navigate by Date:
Prev: Re: PTP hardware timestamps in EPICS facilities Michael Davidsaver via Tech-talk
Next: Re: change MACRO with text-entry value in CSS Phoebus Peter Leban 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  <20202021  2022  2023  2024 
Navigate by Thread:
Prev: Atomtex AT2327 Alarm Dosimeter Markus Kristensson via Tech-talk
Next: Raspberry pi 3 -CAENels EASY-DRIVER 0520 - ethernet victor levy 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  <20202021  2022  2023  2024 
ANJ, 08 Sep 2020 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·