EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  <20042005  2006  2007  2008  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  <20042005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: Re: Initialising an ao record from a constant DOL
From: Andrew Johnson <[email protected]>
To: Benjamin Franksen <[email protected]>
Cc: [email protected]
Date: Fri, 23 Apr 2004 17:13:24 -0500
Benjamin Franksen wrote:

As i understood it, the device support returns 0 by purpose in order to enable bumpless reboot and what Pete wants is to override this behavior with a constant in DOL. As Bob said this is not possible at the moment. But i think it should be possible to change the ao record support so that if DOL is defined with some constant value then this value takes precedence over any value return from the device support's init_record for bumpless reboot.

If an aoRecord device support's init_record routine is not able to set the RVAL field to the actual value read back from the hardware, it *must* return with status 2. If it returns status 0 without setting RVAL the record is going to immediately trash the VAL field with whatever it finds in the RVAL field (probably 0) back-converted into engineering units, which is pretty much going to guarantee a reboot bump.


This is exactly how the bumpless reboot facility that Bob was talking about works. It was meant for any synchronous device support which *is* capable of reading the last written ADC value back from the hardware registers in raw units, and signals this ability to the record by putting that raw data into RVAL and returning 0 from init_record. If it's a device support like GPIB that uses engineering units anyway, it puts that readback value into the VAL field and returns a 2.

A device support with is not capable of the hardware readback should return a 2 from init_record, to retain the contents of the VAL field as set by a constant in the DOL field (which is what Pete was trying to do).

Admittedly the convention used for the value returned there is not particularly obvious, but it is documented and does match that of the read/write routine with 2 meaning do not convert.

There is no need to make any changes to the ao record to do what Pete wants, just fix the device support routine.

- Andrew
--
Dear God, I didn't think orange went with purple until I saw
the sunset you made last night.  That was really cool. - Caro


Replies:
Re: Initialising an ao record from a constant DOL Benjamin Franksen
References:
Re: Initialising an ao record from a constant DOL Bob Dalesio
Re: Initialising an ao record from a constant DOL Andrew Johnson
Re: Initialising an ao record from a constant DOL Benjamin Franksen

Navigate by Date:
Prev: Vacancy at APS John Maclean
Next: Re: Initialising an ao record from a constant DOL Benjamin Franksen
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  <20042005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: Re: Initialising an ao record from a constant DOL Benjamin Franksen
Next: Re: Initialising an ao record from a constant DOL Benjamin Franksen
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  <20042005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 10 Aug 2010 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·