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: Stream Device and Asyn
From: Alan Greer <[email protected]>
To: "[email protected]" <[email protected]>
Date: Mon, 08 Apr 2013 15:16:58 +0100
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 Mark Rivers

Navigate by Date:
Prev: Is there suitable "accelerator" logbook for experiments? Andrei Liyu
Next: RE: Stream Device and Asyn Mark Rivers
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: Is there suitable "accelerator" logbook for experiments? Andrei Liyu
Next: RE: Stream Device and Asyn Mark Rivers
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 ·