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: another asyn question...
From: Heinrich du Toit <[email protected]>
To: TechTalk EPICS <[email protected]>
Date: Tue, 19 Jun 2007 17:28:38 +0200
I'm still having trouble, this time letting the asynRegister interface
work with my asyn driver.

I register a simple asynInt32 interface.
And this works, if I use a simple ai/ao Record.

But when I try process from medm screen I get sigfault at line 1305
because pasynRecPvt->pasynInt32 = 0x0

Now pasynRecPvt gets setup in connectDevice in asynRecord.c
(asyn4-8/asyn/asynRecord/asynRecord.c - line 1076)

Now at line 1135  pasynInt32 gets set correctly according to my
debugger.
Funny thing is that it seems to execute twice - not sure how that works?

Anyways as soon as that is done pasynRecPvt->pasynInt32 does have the
link to my interface.

But then it gets cleared again at line 1161 ??
Obviously I don't have a asynFloat64 interface - I'm trying to test
asynInt32 :)
I don't really understand epics... but it seems like that line is
clearing the wrong pointers??

I changed the code to such:
 /* Get asynFloat64 interface if it exists*/
    pasynInterface = pasynManager->findInterface(pasynUser,
asynFloat64Type, 1);
    if(pasynInterface) {
        pasynRecPvt->pasynFloat64 = (asynFloat64 *)
pasynInterface->pinterface;
        pasynRecPvt->asynFloat64Pvt = pasynInterface->drvPvt;
        pasynRec->f64iv = 1;
    } else {
        pasynRecPvt->pasynFloat64 = 0;
        pasynRecPvt->asynFloat64Pvt = 0;
        pasynRec->f64iv = 0;
    }

and recompiled asyn

and now my problem seems to be solved..

:)
maybe I got outdated code of asyn?




Replies:
RE: another asyn question... Mark Rivers

Navigate by Date:
Prev: Re: asynRecord SEGFAULT? Dirk Zimoch
Next: RE: another asyn question... Mark Rivers
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: Re: asynRecord SEGFAULT? Dirk Zimoch
Next: RE: another asyn question... Mark Rivers
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 ·