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

Subject: RE: dbVerify removed from EPICS 3.16
From: <michael.abbott@diamond.ac.uk>
To: <anj@aps.anl.gov>, <tech-talk@aps.anl.gov>, <mdavidsaver@gmail.com>
Date: Wed, 20 Sep 2017 06:36:35 +0000
From: Michael Davidsaver [mailto:mdavidsaver@gmail.com]
> fyi. http://www.aps.anl.gov/epics/tech-talk/2017/msg00997.php

Yes, I saw that.  Doesn't help my application though.

From: tech-talk-bounces@aps.anl.gov [mailto:tech-talk-
> On 09/19/2017 04:34 AM, michael.abbott@diamond.ac.uk wrote:
> > I have just discovered that the dbVerify function has been removed from
> > EPICS 3.16.  I use the functionality provided by this function to
> > validate databases as they are statically constructed (in iocbuilder
> > and epicsdbbuilder).  At present DLS is still using EPICS 3.14, so I am
> > only learning about this from external reports.
> 
> I don't recognize a program named dbVerify;

I'm talking about the dbVerify entry point which was part of the API provided by EPICS base until it was deleted in 3.15.  I use this function to validate databases as I statically build them using the two tools that I just named.

I don't know how to make myself any clearer.  Andrew, in your response you talk about dbReadTest and perl parsing and so forth ... which has nothing to do with what I'm doing.

Both the iocbuilder (which has been around for over a decade now) and epicsdbbuilder (which is cut down from iocbuilder) are used to GENERATE database (.db) files from Python scripts, see for example:

	https://github.com/Araneidae/epicsdbbuilder/blob/master/README.rst

The important point here is that I need to validate the record field assignments as they are being made, and presently use dbVerify which I load from libdbStaticHost.so or libdbCore.so.  The example code in the linked file above still works with EPICS 3.15, and dbVerify still works to prevent invalid assignments.  This functionality is now lost to me in 3.16.

Just to be clear: if you run the 7 lines of Python in the README I've linked (pointing to your own EPICS base instead, of course), it will generate a file with the following content:


# This file was automatically generated on Wed 20 Sep 2017 07:30:00 BST.
# 
# *** Please do not edit this file: edit the source file instead. ***
# 
#% macro, DEVICE, Device name

record(calc, "$(DEVICE):CALC")
{
    field(CALC, "A+B")
    field(INPA, "$(DEVICE):TEST.VAL")
    field(INPB, "$(DEVICE):CALC")
    field(SCAN, "1 second")
}

record(ao, "$(DEVICE):TEST")
{
}


>  there was a tool called
> dbReadTest which came with 3.14 and matches the functionality you're
> describing. However it relied on the dbStaticHost library, the
> functionality for which was deleted in 3.15 (this was originally
> provided for use by dbExpand and various database design tools, and
> stored all field value data as strings).
> 
> > Has this functionality been replaced by anything equivalent?  The
> > ability to statically validate assignments to database fields is very
> > useful, it substantially increases my confidence that the generated
> > database will actually load!
> 
> We don't provide a replacement for dbReadTest at the moment. The DBD
> file parsing functionality (used at build-time for converting .dbd files
> into .h files) was converted into Perl modules and scripts, but there
> wasn't an urgent need for parsing DB files so Perl scripts for that
> haven't been included (I have some, but IIRC they can't yet parse the
> new JSON field data that was added for Base-3.16.1).
> 
> You should be able to use the 3.14 version of dbReadTest with 3.15.4
> IOCs but in 3.15.5 we changed the promptgroup values, so that doesn't
> work any more now.
> 
> It may be possible to create another program like dbReadTest by
> bastardizing the softMain.c that is part of the softIoc, but it would
> have to dynamically create its own registerRecordDeviceDriver data from
> the IOC's DBD file (that data is normally compiled into the IOC), and
> that won't be trivial to do.
> 
> Evidently I need to finish off my Perl DB parser, but I don't think that
> will make the upcoming EPICS-7 release.
> 
> - Andrew
> 
> --
> Arguing for surveillance because you have nothing to hide is no
> different than making the claim, "I don't care about freedom of
> speech because I have nothing to say." -- Edward Snowdon

-- 
This e-mail and any attachments may contain confidential, copyright and or privileged material, and are for the use of the intended addressee only. If you are not the intended addressee or an authorised recipient of the addressee please notify us of receipt by returning the e-mail and do not use, copy, retain, distribute or disclose the information in or attached to the e-mail.
Any opinions expressed within this e-mail are those of the individual and not necessarily of Diamond Light Source Ltd. 
Diamond Light Source Ltd. cannot guarantee that this e-mail or any attachments are free from viruses and we cannot accept liability for any damage which you may sustain as a result of software viruses which may be transmitted in or with the message.
Diamond Light Source Limited (company no. 4375679). Registered in England and Wales with its registered office at Diamond House, Harwell Science and Innovation Campus, Didcot, Oxfordshire, OX11 0DE, United Kingdom

Replies:
Re: dbVerify removed from EPICS 3.16 Andrew Johnson
References:
dbVerify removed from EPICS 3.16 michael.abbott
Re: dbVerify removed from EPICS 3.16 Andrew Johnson

Navigate by Date:
Prev: Re: dbVerify removed from EPICS 3.16 Michael Davidsaver
Next: RE: dbVerify removed from EPICS 3.16 michael.abbott
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
Navigate by Thread:
Prev: Re: dbVerify removed from EPICS 3.16 Michael Davidsaver
Next: Re: dbVerify removed from EPICS 3.16 Andrew Johnson
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
ANJ, 20 Sep 2017 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·