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 2025 | 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 2025 |
<== Date ==> | <== Thread ==> |
---|
Subject: | Re: stream/asyn devices |
From: | Dirk Zimoch <[email protected]> |
To: | Emmanuel Mayssat <[email protected]> |
Cc: | epics <[email protected]> |
Date: | Fri, 27 Jul 2007 10:01:44 +0200 |
Update on stream device records
Stream records are actually quite simple to implement. I found what appears to be bugs in the implementation, but some could describe those as features. Mainly the entire part of the afternoon was spend on trying to find out how the terminator is matched.
Although terminator appears to be of unlimited length in stream, it seems that asyn impose its 2 chars limits for eos. As a result the stream terminator consist of the last 2 char of its value.
Stream device can actually handle http connection (not permanent connection) with the "disconnect" protocol option. That was a good surprise.
The matching works well (once the terminator issue was handled), but I would have loved traditional regex matching. Matching a complex/long reply like a web page seems tedious.
But overall, I have been impressed by this record and would encourage all of you to have a closer look at stream. BTW, I use stream from the synApps-5.2 package.
Best regards, Dirk
-- Emmanuel Mayssat
On Thu, 2007-07-26 at 14:59 -0700, Emmanuel Mayssat wrote:Hello again,
I have a device which has a web server and a simple web page. My record should fetch the web page and extract the value between the <epics> and </epics> tags. Can asyn do that? ( it probably can ;)
Better yet, I looked at the streamDriver which is also said to work on TCP/IP. Can stream records do that? One could argue that the TCP/IP connection is not permanent (i.e the server kicks you out if the client is idle, but asyn should auto-reconnect right?)
http://epics.web.psi.ch/software/streamdevice/doc/
Also is stream the new devGpib ?
-- Emmanuel