I can't think of any reason why it would be doing a read. asyn device support does attempt a read at iocInit on many output records, but not on stringout records.
Could this be from a "flush" operation? Your driver is printing the message "device read"?
Mark
________________________________________
From: Alan Greer [[email protected]]
Sent: Monday, April 08, 2013 9:42 AM
To: Mark Rivers
Cc: [email protected]
Subject: Re: Stream Device and Asyn
Hi sure, here it is:
record(stringout, "T1:STRING")
{
field (DTYP, "stream")
field (OUT, "@test.proto stringIO SSH1")
}
I should say that originally I was attempting to write the contents of
the string record to the device, instead of the hard coded string
"cpu\n". I changed it to the hard coded value when I couldn't get the
original setup to work.
Kind regards, Alan
On 04/08/2013 03:36 PM, Mark Rivers wrote:
> Can you send the database you are using that invokes that protocol file?
>
> -----Original Message-----
> From: [email protected] [mailto:[email protected]] On Behalf Of Alan Greer
> Sent: Monday, April 08, 2013 9:17 AM
> To: [email protected]
> Subject: Stream Device and Asyn
>
> Hi all,
>
> I have an Asyn driver (SSH) that I'm attempting to use with Stream Device.
>
> My setup
>
> EPICS_BASE=/home/epics/R3.14.12.2/base
> ASYN=/home/epics/R3.14.12.2/asyn4-18
> STREAM=/home/epics/R3.14.12.2/stream2-6
>
> Here is my protocol file
>
> >> more test.proto
>
> stringIO {
> out "cpu\n";
> }
>
>
> When I process the record that executes the stringIO routine I get the
> following IOC output (with asyn trace set)
>
> epics> 2013/04/08 15:03:39.859 SSH1 addr -1 queueRequest priority 0 not
> lockHolder
> 2013/04/08 15:03:39.859 SSH1 schedule queueRequest timeout
> 2013/04/08 15:03:39.859 asynManager::portThread port=SSH1 callback
> 2013/04/08 15:03:39.859 SSH1 addr -1 queueRequest priority 0 not lockHolder
> 2013/04/08 15:03:39.859 SSH1 schedule queueRequest timeout
> 2013/04/08 15:03:39.859 asynManager::portThread port=SSH1 callback
> 2013/04/08 15:03:39.859 device read.
> 2013/04/08 15:03:39.859 Close device connection (fd -1221589168): Read error
> 2013/04/08 15:03:39.859 device read.
> 2013/04/08 15:03:39.859 Open connection to device reason:0
> 2013/04/08 15:03:40.346 Opened connection to device
> 2013/04/08 15:03:40.347 Close device connection (fd -1221589168): Read error
> 2013/04/08 15:03:40.347 device read.
>
> When I look at those messages I agree that the device read will return a
> read error, as there is nothing to read back. What I don't understand
> is why readIt is called at all. I was expecting the protocol function
> to only call into writeIt. What I see is that readIt appears to be
> called with a timeout of 0. Can anyone help me with this? My asyn
> driver is (loosely) based on the drvAsynIPPort driver, with an
> additional library in place of the actual socket calls made, and
> simplified as much as possible.
>
> The output messages continue indefinitely when I process the record,
> disconnecting, reconnecting, attempt a read... etc.
>
> I have successfully used the driver with a custom asyn motor record
> device support layer, and so the driver is functional (at least to some
> extent!)
>
> Any help or suggestions would be appreciated.
>
> Kind regards, Alan Greer
>
>
- Replies:
- Re: Stream Device and Asyn Alan Greer
- References:
- Stream Device and Asyn Alan Greer
- RE: Stream Device and Asyn Mark Rivers
- Re: Stream Device and Asyn Alan Greer
- Navigate by Date:
- Prev:
Re: Stream Device and Asyn Alan Greer
- Next:
Re: Stream Device and Asyn Alan Greer
- 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
2018
2019
2020
2021
2022
2023
2024
- Navigate by Thread:
- Prev:
Re: Stream Device and Asyn Alan Greer
- Next:
Re: Stream Device and Asyn Alan Greer
- 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
2018
2019
2020
2021
2022
2023
2024
|