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: [asyn] link already open!
From: Pavel Maslov <[email protected]>
To: Dirk Zimoch <[email protected]>, EPICS Tech Talk <[email protected]>
Date: Fri, 9 Aug 2013 12:24:00 +0200
Hi Dirk,

You are absolutely right - I am using streamdevice. 
drvAsynIPPortConfigure("lambda1","127.0.0.1:7001")
asynOctetSetInputEos("lambda1", -1, "\n")
asynOctetSetOutputEos("lambda1", -1, "\n")
asynSetTraceIOMask("lambda1",-1,0x3)
asynSetTraceMask("lambda1",-1,0x5)




On Fri, Aug 9, 2013 at 11:49 AM, Dirk Zimoch <[email protected]> wrote:
On 09.08.2013 11:42, Dirk Zimoch wrote:
On 09.08.2013 11:20, Pavel Maslov wrote:
Hello all,

When can this message pop up:

2013/08/09 11:03:11.051131 lambda1 lambda-ps:CURR:MAX:RBV:
pasynCommon->connect() failed: 127.0.0.1:7001 <http://127.0.0.1:7001>:
Link already open!
2013/08/09 11:03:11.052968 lambda1 lambda-ps:CURR:MAX:RBV: Protocol
aborted


The message itself looks like coming from StreamDevice. But without more
information I cannot say why the connect() call of asyn fails. At least
report the port configuration and the protocol.


What StreamDevice does:

    pasynManager->isConnected(pasynUser, &connected);
    if (!connected)
    {
        status = pasynCommon->connect(pvtCommon, pasynUser);
        if (status != asynSuccess)
        {
            error("%s: pasynCommon->connect() failed: %s\n",
                clientName(), pasynUser->errorMessage);
            return false;
        }
    }

Dear Asyn-experts: Is this wrong?
At least it is a race condition. Is there any atomic way to say "Connect if not already connected" ?

Dirk






--
-- 
Regards,


Pavel Maslov, MS
Controls Engineer
Cosylab d.d.
Ljubljana, Slovenia

Mobile: +386 406 32 571


Replies:
Re: [asyn] link already open! Pavel Maslov
References:
[asyn] link already open! Pavel Maslov
Re: [asyn] link already open! Dirk Zimoch
Re: [asyn] link already open! Dirk Zimoch

Navigate by Date:
Prev: Re: [asyn] link already open! Dirk Zimoch
Next: Re: [asyn] link already open! Pavel Maslov
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: Re: [asyn] link already open! Dirk Zimoch
Next: Re: [asyn] link already open! Pavel Maslov
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 ·