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  <20092010  2011  2012  2013  2014  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  <20092010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: re: How to let Hytec8401ADC works on interrupt way ?
From: "liuping" <[email protected]>
To: <[email protected]>
Cc: [email protected]
Date: Thu, 27 Aug 2009 10:53:29 +0800

Hello Martin,

Thank you for your reply.

The Hytec  corporation has updated 8401module to 100Khz clock rate.  The voltage of trigger pulse is ok. The 8992 terminal block, 8002 carrier and SCSI cable are purchased from Hytec corp. The hardware and connection is no problem.

I noticed that “Hy8401” was used in your record DTYP field. But in my example, “Hy8401ip” was filled in DTYP filed. That means your Hy8401software driver and mine is different.

 


: Martin Heiniger [mailto:[email protected]]
: 2009年8月26 14:37
: [email protected]
: liuping
: Re: How to let Hytec8401ADC works on interrupt way ?

 

Sorry I forgot to tell you about my records:

record(ai,"FINLB01-DWCM:VOLTAGE") {
                field(DESC, "Wall Current Monitor (WCM)")
                field(DTYP, "Hy8401")
                field(INP,  "#C91 S0 @")
               
field(SCAN, "I/O Intr")
                field(EGU,  "V")
                field(LOPR, "-10")
                field(HOPR, "10")
                field(PREC, "3")
                field(EGUL, "-10")
                field(EGUF, "10")
                field(LINR, "LINEAR")
                field(FLNK, "FINLB01-DWCM:CHARGE")}

record(calcout,"FINLB01-DWCM:CHARGE") {
                field(DESC, "Wall Current Monitor (WCM)")
                field(INPA, "FINLB01-DWCM:VOLTAGE")
                field(INPB, "25.6")
                field(CALC, "A/(B/1000)")
                field(EGU,  "pC")
                field(PREC, "0")
                field(FLNK, "FINLB01-DWCM:VOLTAGE-WF")}

record(waveform,"FINLB01-DWCM:VOLTAGE-WF") {
                field(DESC, "waveform of analog inp.")
                field(DTYP, "Hy8401")
                field(INP,  "#C91 S0 @")
                field(NELM, "24")
                field(FTVL, "USHORT")
                field(EGU,  "Rawdata")}

PS: card number "#C91" means: VME crate slot 9, ADC IP on socket A = 1, this makes 91.


Martin Heiniger wrote:

Hello LIU

I have here an working example, used for a ICT charge measurement at the SwissFEL teststand here at PSI, a analog voltage from a box car integrator to a Hytec 8401 ADC. Please see below the part of the startup.scrip.
Could it be that you use a clock rate (clkr "15") witch is not possible? I use "14" and "15" is not documented. Make sure that your external pulse is high enough in voltage! For example 3.3 Volts is too low, I have experienced. 5 Volts is OK. And are you sure about the connection of your external interrupt? Do you use a terminal block with a SCSI cable to a Hytec transition module? Check for example here http://www.hytec-electronics.co.uk/DataSheetHtml/8201.html the connection. Every time a interrupt appears the red led (A...D, depends where you placed the ADC) on the 8002 carrier should blink.

For IP module A the external trigger is on SCSI connector 1 (lowest, on the bottom of the transition module) on pins 43 and 18.

XTrig1 High

RP2/A23

Skt1/43

XTrig1 Low

RP2/C23

Skt1/18

(Source: http://www.hytec-electronics.co.uk/DataSheetHtml/8201.html)

Good luck and best regards!
Martin

=========================================
Martin Heiniger
Common Applications
Control System SwissFEL
Paul Scherrer Institut (PSI)
WBGB/002
CH-5232 Villigen PSI
SWITZERLAND
 
Telefon: +41 (0)56 310 54 89
E-Mail: [email protected]
Internet: www.psi.ch
=========================================
 



#--------------------------------------------------------------------
# Analog Input Configuration
#
# cn     card number as used in INP fields.
# ba     base address of the board.
# iv     interrupt vect number. If 0, then one will be automatically
#        selected
# il     board's interrupt level
# en     enable/disable IRQ at start
# ai     analog input type: 0=differential, 1=single-ended (not used)
# cs     clock source: 0=internal, 1=external
# cr     clock Rate: 1=2Hz, 2=5Hz, 3=10Hz, 4=20Hz, 5=50Hz, 6=100Hz,
#                    7=200Hz, 8=500Hz, 9=1kHz, 10=2kHz, 11=5kHz, 12=10kHz,
#                    13=20kHz, 14=50kHz
# in     1 enables front panel inhibit
# sa     number of samples
# sp     space between samples (1=use each sample, 10=use every
#        10th sample)
# tr     trigger: if non-zero use external trigger and make this number of
#        conversions. If zero use continuous (circular buffer) sampling  
#
#              (cn, ba,     iv,   il, en, ai, cs, cr, in, sa,  sp, tr)
#
# Analog Input Carrierboard with LEMO Transition Module (Slot 9, Module A)
# The Trigger comes from the Event Receiver Front Panel Output 0 (LEMO) and
# is connected to the LEMO Transition Module to LEMO connctor "C" (Clock) on
# section A. Note: On this type of transition module, the labels on the
# connectors "C" and "T" are mixed up. The "C" connector is the Trigger and
# the "T" connector is the Clock!
# The number of conversions (tr) has to match with the NELM (number of
# elements) in the .subs file!
# The duration (pulse with) of the external trigger has to be bigger than
# the period of the ADC clock (14 = 50 kHz = 20 us), multiplied by the number
# of samples, here it is 20 us x 24 samples = 480 us, so the trigger duration
# must be bigger, let's make it 500 us.

Hy8401Configure(91, 0x4800, 0x42, 4,  1,  0,  0,  14, 0,  1,  1,  24)
 
#--------------------------------------------------------------------



liuping wrote:

Hi, everyone

I have the trouble of Hytec 8401ADC working way. I can let it works well if I set the SCAN field to 1 second. But if I/O Intr" was set, there are no any responses. I use 10Hz/5V pulse to trigger Hy8401ADC. The driver was downloaded from SLS. So who can help me to let it works on interrupt way?

In my opinion, I think I made some wrong parameters in the function of Hy8401ipConfigure(). I dont know how to set the parameters of vector and interrupt state. In my example, I set intl=3, inte=1. Also I am not sure I need to change some switch on slots of VME or not.

 

They are abstracted from st.cmd :

#                                      slot int options

 IPAC6 = ipacEXTAddCarrier(&EXTHy8002, "8 6 10")

 

#-------- 8401 (Analogue Input)------------------------------------------------

#                                                      card,  slot,               ipsl,   intl,        inte,         aity,       clks,            clkr,       inhi,         samp,         spac,         trig

Hy8401ipConfigure (  60, IPAC6,    A,  3,    1,    0,    0,    15,    0,    100,    1,   100)

 

It is the record what I used:

record(ai, "Hy8401:ADC-01")

{

  field(SCAN, "I/O Intr")

  field(LINR, "LINEAR")

  field(EGUF, "10")

  field(EGUL, "-10")

  field(DESC, "ADC Site A Ch 0")

  field(PREC, "6")

  field(EGU, "Volts")

  field(HOPR, "10")

  field(LOPR, "-10")

  field(DTYP, "Hy8401ip")

  field(INP, "#C60 S0 @")

}

 

They are the output information of VME/IOC:

#                                      slot int options

 IPAC6 = ipacEXTAddCarrier(&EXTHy8002, "8 6 10")

Id: drvHy8002.c,v 1.10 2001/11/20 12:21:42 wscott Exp

8002 initialise 8 6 10

PROM manufacturer ID: 0x8003 (HyTec Electronics Ltd., Reading, UK)

PROM model #: 0x8002, board rev. 0x03

PROM Xilinx rev.: 0x03, 0x00, 0x07

PROM Serial #: 0x00 0x00 0x00 0x00 0x01 0xcf

new symbol "IPAC6" added to symbol table.

IPAC6 = 0x1ee6a5a0: value = 0 = 0x0

 

#-------- 8401 (Analogue Input)------------------------------------------------

#                  card,  slot, ipsl, intl, inte, aity, clks,  clkr, inhi, samp, spac, trig

Hy8401ipConfigure (  60, IPAC6,    0,  3,    1,    0,    0,    15,    0,    100,    1,   100)

$Id: drvHy8401ip.c,v 1.8 2005/10/27 09:07:01 mga83 Exp $

Hy8401ipConfigure: card 60, VME slot 0, IP slot 0,

           vector 3, itr state 1, ai type 0,

           clock src 0, clock rate 15, inhibit 0,

           samples 100, spacing 1, trigger 100

 

value = 0 = 0x0

 

 

 

 

===================================
 

LIU Ping

 

Beamline Control Group
Shanghai Synchrotron Radiation Facility
Shanghai Institute of Applied Physics
Chinese Academy of Sciences
Zhangheng Rd 239,Pudong Dist.,
Shanghai 201204
China
Tel:+86-21-33933237

 

http://ssrf.sinap.ac.cn
===================================

 

 

 


Navigate by Date:
Prev: Re: problem using epid record Ralph Lange
Next: requesting help for Running VDCT using JRE D.Chinnadurai
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  <20092010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: Re: How to let Hytec8401ADC works on interrupt way ? graham
Next: problem using epid record Maurizio Montis
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  <20092010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 31 Jan 2014 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·