g+
g+ Communities
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  <20122013  2014  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  <20122013  2014 
<== Date ==> <== Thread ==>

Subject: Re: LeCroy DSO using VXI
From: "Nicholas P. DiMonte" <npd@aps.anl.gov>
To: Jörn Wüstenfeld <j.wuestenfeld@hzdr.de>
Cc: EPICS Tech Talk <tech-talk@aps.anl.gov>
Date: Wed, 12 Dec 2012 09:54:07 -0600
Try using a asynRecord to debug your connection. Using the displays supplied with asynRecord will allow you to type in commands, like *IDN?, and changed the error flags on the fly to monitor all transactions.

Its been very useful when I need to debug Tektronix/Agilent scopes.
Nick D.

O
n 12/12/2012 9:25 AM, Jörn Wüstenfeld wrote:
Hello,

I'm running into a problem trying to access a LeCrow WR640Zi DSO using its LXI interface.

In st.cmd I have:

vxi11Configure("osc","192.168.0.1",0,0.0,"inst0",0,0) 
asynSetTraceMask("osc",3,0xff)

In XStream.proto:

identify {
	out "*IDN?";
	in "%s";
  @init {
		out "*IDN?";
		in "%s";
  }
}

And in my db file:

record (stringin, "OSC:identify")
{
  field (DTYP, "stream")
  field (INP, "@XStream.proto identify $(interface)")
}

If I start my IOC under Linux, I get the following output:

#!../../bin/linux-x86/crpc
< envPaths
epicsEnvSet("ARCH","linux-x86")
epicsEnvSet("IOC","ioccrpc")
epicsEnvSet("TOP","/aaa/apps")
epicsEnvSet("EPICS_BASE","/aaa/base-3.14.12.2")
epicsEnvSet("ASYN","/aaa/modules/src/asyn4-20")
epicsEnvSet("STREAM_PROTOCOL_PATH","/aaa/apps/protocols")
cd /aaa/apps
## Register all support components
dbLoadDatabase "dbd/crpc.dbd"
crpc_registerRecordDeviceDriver pdbbase
vxi11Configure("osc","192.168.0.1",0,0.0,"inst0",0,0) 
asynSetTraceMask("osc",3,0xff)
## Load record instances
dbLoadRecords "db/LeCroy.db"
cd /aaa/apps/iocBoot/ioccrpc
iocInit
Starting iocInit
############################################################################
## EPICS R3.14.12.2 $Date: Mon 2011-12-12 14:09:32 -0600$
## EPICS Base built Jul 12 2012
############################################################################
2012/12/12 14:30:54.111 osc -1 registerInterruptUser
2012/12/12 14:30:54.112 osc -1 registerInterruptUser
2012/12/12 14:30:54.112 osc addr -1 queueRequest priority 3 not lockHolder
2012/12/12 14:30:57.619 osc vxi11 clientCall errno Permission denied clnt_stat 5
2012/12/12 14:30:57.619 osc vxiCreateIrqChannel (create_intr_chan): RPC: Timed out

2012/12/12 14:30:57.619 osc Warning -- SRQ not operational.
2012/12/12 14:31:01.623 osc vxi11 clientCall errno Success clnt_stat 5
osc vxiSrqEnable RPC error : RPC: Timed out

2012/12/12 14:31:01.623 osc asynGpib:pollAddr srqEnable 
2012/12/12 14:31:01.623 osc asynGpib:srqHappened
2012/12/12 14:31:01.623 osc addr -1 queueRequest priority 1 not lockHolder
2012/12/12 14:31:01.623 asynManager connect queueCallback port:osc
2012/12/12 14:31:01.623 osc addr -1 queueRequest priority 0 not lockHolder
2012/12/12 14:31:01.623 osc schedule queueRequest timeout
2012/12/12 14:31:01.623 asynManager::portThread port=osc callback
2012/12/12 14:31:01.623 asynManager::portThread port=osc callback
2012/12/12 14:31:01.623 osc -1 vxiWrite numchars 5
2012/12/12 14:31:05.627 osc vxi11 clientIoCall errno Success clnt_stat 5
2012/12/12 14:31:05.627 osc CBM:HZDR:OSC:identify: asynError in write: osc RPC failed                                                                 
2012/12/12 14:31:05.627 _main_ OSC:identify: @init handler failed      
2012/12/12 14:31:05.627 _main_ OSC:identify: Record initialization failed                                                                              
iocRun: All initialization complete                                             


Here the Error messages fro clientCall and clientIOCall are missleading, as drvVxi11.c uses strerror instead of clnt_sperrno to print the rpc related error message from the return value of clnt_call(). Insted it should always read : Timeout.
I'm using base 3.14.12.2 and asyn 4.20.


In the log of the scope I see that it recieves the *IDN? query, and that it also sends the correct return string. Probably due to the fat, that it did ot set up the SRQ handler on the socket correctly.

Has anybody an idea how to debug this further? I have seen in the archive the recommendation to use an IOC on the scope directly (Win7) using the supplied ActiveX program to access thescope software. But I prefere the IOC externaly, as I had to install an AV Software on the scope to be allowed to include it in our network which consumes quite a bit of CPU.

Regards,

Joern



References:
LeCroy DSO using VXI Jörn Wüstenfeld

Navigate by Date:
Prev: LeCroy DSO using VXI Jörn Wüstenfeld
Next: RE: "Connection refused" when running Ethernet/RS232 application Mark Rivers
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  <20122013  2014 
Navigate by Thread:
Prev: LeCroy DSO using VXI Jörn Wüstenfeld
Next: Re: LeCroy DSO using VXI Eric Norum
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  <20122013  2014 
ANJ, 18 Nov 2013 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· EPICSv4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·