EPICS Home

Experimental Physics and Industrial Control System


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

Subject: asynPortDriver Question
From: "Szalata, Zenon M." <[email protected]>
To: Mark Rivers <[email protected]>
Cc: "[email protected]" <[email protected]>
Date: Sat, 26 Mar 2011 12:54:49 -0700

Hi Mark,

I am using a four record set to write analog data to a set point register in a power supply and to keep reading and writing this register in sync.  This technique is what you suggested as a solution to a question I had.  Here are the four records:

 

#---- $(DESC) ------------------------------

record( ao, "$(P):AO:SC:$(ITEM)"){

  field( DESC, "$(DESC):")

  field( OUT,  "$(P):AO:$(ITEM) PP")

  field( DRVL, "$(DRVL)")

  field( DRVH, "$(DRVH)")

}

record( ao, "$(P):AO:$(ITEM)"){

  field( SDIS, "$(P):AO:$(ITEM):Sync.PACT")

  field( DISV, "1")

  field( DTYP, "asynFloat64")

  field( OUT,  "@asyn($(PORT),0,1)AO_$(ITEM)")

}

record( ai, "$(P):AI:$(ITEM)"){

  field( DTYP, "asynFloat64")

  field( INP,  "@asyn($(PORT),0,1)AI_$(ITEM)")

  field( SCAN, "I/O Intr")

  field( EGU,  "$(EGU)")

  field( FLNK, "$(P):AO:$(ITEM):Sync")

}

record( ao, "$(P):AO:$(ITEM):Sync"){

  field( DOL,  "$(P):AI:$(ITEM) NPP")

  field( OMSL, "closed_loop")

  field( OUT,  "$(P):AO:SC:$(ITEM) PP")

}

 

An EDM Text Control widget connected to the “AO:SC” record is used to write a new value to the set point register.  Depending on some other configuration parameters that the power supply is set up with, write set point might fail.  When that happens, my writeFloat64 routine returns asynError and the SEVR gets set INVALID in the “$(P):AO:$(ITEM)” record.  I would like the EDM widget to reflect this alarm condition.  It does not do it because it is not connected to the AO record that is in an alarm state and I don’t know how to transfer this alarm information to the record the EDM widget is connected to.

 

I wonder if it is possible to control alarm state of an EPICS record via asynPortDriver, a record that is not being processed at the moment?  That is, is there a way other than returning a failed completion code from a processing routine (like writeInt32) to put a record in an alarm state?

 

Thanks,

Zen


Replies:
RE: asynPortDriver Question Mark Rivers

Navigate by Date:
Prev: RE: epicsqt first try Andrew Rhyder
Next: RE: asynPortDriver Question Mark Rivers
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  <20112012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: Re: GPIB DCL Robert Emery
Next: RE: asynPortDriver Question Mark Rivers
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  <20112012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024