EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  <20072008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  <20072008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: Re: writing your own stream cronverter
From: Emmanuel Mayssat <[email protected]>
To: Dirk Zimoch <[email protected]>
Cc: [email protected]
Date: Mon, 03 Dec 2007 13:45:30 -0800
To answer my own question...
The type returned by parse is the type of the EPICS record.

To populate several records with the same reply, one needs to use a
trigger record (a standard ai record (devaiStream)) and other slave
records (scan set to Intr I/O scan and protocol with only "in"
directives). The "out" directive is set in the protocol of the trigger
record.

Cheers,
--
Emmanuel




On Mon, 2007-12-03 at 11:57 -0800, Emmanuel Mayssat wrote:
> Dirk, others,
> 
> I am trying to write a new converter.
> That converter is almost like the RawConvert except:
> * the bit order and meaning are the same a C float ( sign + mantissa +
> exponent )
> * the content is coded on 4 bytes
> * Width is not meaningful, big/small endian may be
> * Several values should be extracted from the same reply ( 25 ai ). So
> devaiStream does not work.
> 
> 
> I looked at the existing converter.
> A converter has 3 methods parse, print, read/scan.
> Parse returns a type (long, double, string, etc.), what is this type
> referring to? The input (4*8 bits), the value (float), other ?
> I understand that it is used to find the correct print/read methods but
> what should it be in my case? 
> 
> If Read/scan method returns the # of bytes read, I should be forced to 4
> in my case? Is the return value always the number of bytes?
> 
> I want to assign the values of several records based on the returned
> message. Should I create a custom record with 25 additional fields when
> compared to ai and then soft link them to other AI. Is there a way to
> use devaiStream and directly populate the 25 records? 
> 
> getStatus {
> out "GET STATUS"
> in  "%(record1.val)R%(record2.val)R%(record3.val)R"
> }
> 
> Thanks,
> 
> --
> Emmanuel
> 


Replies:
Re: writing your own stream converter Emmanuel Mayssat
References:
writing your own stream cronverter Emmanuel Mayssat

Navigate by Date:
Prev: writing your own stream cronverter Emmanuel Mayssat
Next: device support for output connected to volatile device John Dobbins
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  <20072008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: writing your own stream cronverter Emmanuel Mayssat
Next: Re: writing your own stream converter Emmanuel Mayssat
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  <20072008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 10 Nov 2011 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·