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

Subject: RE: write record device support
From: Mark Rivers <[email protected]>
To: "'[email protected]'" <[email protected]>, tech-talk <[email protected]>
Date: Mon, 11 Mar 2013 14:48:36 +0000
In your record you can define the field to have the attribute special(SPC_MOD) and in your record you can implement the special() function.  Then you could set a flag that device support uses to determine which fields have changed.  The calcoutRecord in base is an example of a record that defines a number of fields (CALC, INPA, etc.) to be SPC_MOD, and then does something with these fields in the special() function in the record.

It sounds like your application would be well suited to using streamDevice support. In that case you don't need to write any C code at all, i.e. not a new record or new device support.  You just write a streamDevice protocol file that specifies each of the messages you need to send and receive.

Mark


-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of [email protected]
Sent: Monday, March 11, 2013 9:10 AM
To: tech-talk
Subject: write record device support

Hi all! Sorry for ask serveal simple questions.

Here is what I'm doing:
I had write a regular Ioc application connect with a board using TCP/IP socket. In the IOC, I use the system record type like ao, ai, bi and etc. So I have many records or PVs. And for each record I should send or receive different message to the board.
Now I want to write a new record type(nodeRecord) by myself instead of using system record type. Maybe it is not a good method.
But I want to have a try.

In the new record type(nodeRecord), I turn the previously IOC records to the nodeRecord's fields.
And I can access the fields in the client using ca library.
But I can't know what field was processed in the device support so that I can't konw what message I should send to the board.
So how do I konw which field I was processed in the device support? 
Now I just compare the each field value and judge which field value was changed. This is too stupid.
Do you have any better ideals?

Thank you all!




References:
write record device support ahwwq

Navigate by Date:
Prev: I/O Intr scanning Vishnu Patel
Next: Re: gethostbyname and getaddrinfo - multiple DNS entries for a hostname Michael Davidsaver
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  <20132014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: write record device support ahwwq
Next: I/O Intr scanning Vishnu Patel
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  <20132014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 20 Apr 2015 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·