caenv1190B.h

Go to the documentation of this file.
00001 /*********************************************************************
00002 
00003   Name:         v1190B.h
00004   Created by:   Pierre-Andre Amaudruz
00005 
00006   Contents:     V1190B 64ch. TDC
00007                 
00008   $Log$
00009   Revision 1.1  2005/08/23 22:27:20  olchanski
00010   TRIUMF drivers for sundry CAEN VME modules
00011 
00012 *********************************************************************/
00013 
00014 #ifndef V1190B_H_INCLUDED
00015 #define V1190B_H_INCLUDED 1
00016 
00017 #
00018 /* V1190 Base address */
00019 #define  V1190_MAX_CHANNELS      (uint16_t) 64
00020 #define  V1190_REG_BASE          (uint16_t) (0x1000>>1)
00021 #define  V1190_CR_RW             (uint16_t) (0x1000>>1)
00022 #define  V1190_SR_RO             (uint16_t) (0x1002>>1)
00023 #define  V1190_DATA_READY        (uint16_t) (0x0001)
00024 #define  V1190_ALMOST_FULL       (uint16_t) (0x0002)
00025 #define  V1190_FULL              (uint16_t) (0x0004)
00026 #define  V1190_TRIGGER_MATCH     (uint16_t) (0x0008)
00027 #define  V1190_HEADER_ENABLE     (uint16_t) (0x0010)
00028 #define  V1190_GEO_REG_RW        (uint16_t) (0x001E)
00029 #define  V1190_MODULE_RESET_WO   (uint16_t) (0x1014>>1)
00030 #define  V1190_SOFT_CLEAR_WO     (uint16_t) (0x1016>>1)
00031 #define  V1190_SOFT_EVT_RESET_WO (uint16_t) (0x1018>>1)
00032 #define  V1190_SOFT_TRIGGER_WO   (uint16_t) (0x101A>>1)
00033 #define  V1190_EVT_CNT_RO        (uint16_t) (0x101C>>1)
00034 #define  V1190_EVT_STORED_RO     (uint16_t) (0x1020>>1)
00035 #define  V1190_FIRM_REV_RO       (uint16_t) (0x1026>>1)
00036 #define  V1190_MICRO_RW          (uint16_t) (0x102E>>1)
00037 #define  V1190_MICRO_HAND_RO     (uint16_t) (0x1030>>1)
00038 #define  V1190_MICRO_WR_OK       (uint16_t) (0x0001)
00039 #define  V1190_MICRO_RD_OK       (uint16_t) (0x0002)
00040 #define  V1190_MICRO_TDCID       (uint16_t) (0x6000)
00041 #define  V1190_RESOLUTION_RO     (uint16_t) (0x2600)
00042 #define  V1190_TRIGGER_MATCH_WO  (uint16_t) (0x0000)
00043 #define  V1190_CONTINUOUS_WO     (uint16_t) (0x0100)
00044 #define  V1190_ACQ_MODE_RO       (uint16_t) (0x0200)
00045  
00046 int  udelay(int usec);
00047 int  v1190_EventRead(DWORD *base, DWORD *pdest, int * nentry);
00048 int  v1190_DataRead(DWORD *base, uint32_t *dest, int maxwords);
00049 void v1190_SoftReset(uint16_t *pbase);
00050 void v1190_SoftClear(uint16_t *pbase);
00051 void v1190_SoftTrigger(uint16_t *pbase);
00052 void v1190_DataReset(uint16_t *pbase);
00053 int  v1190_DataReady(uint16_t *pbase);
00054 int  v1190_EvtCounter(uint16_t *pbase);
00055 int  v1190_EvtStored(uint16_t *pbase);
00056 int  v1190_MicroCheck(const uint16_t *pbase, int what);
00057 int  v1190_MicroWrite(uint16_t *pbase, uint16_t data);
00058 int  v1190_MicroRead(const uint16_t *pbase);
00059 int  v1190_MicroFlush(const uint16_t *pbase);
00060 int  v1190B_TdcIdList(uint16_t *pbase);
00061 int  v1190B_ResolutionRead(uint16_t *pbase);
00062 int  v1190B_TriggerMatchingSet(uint16_t *pbase);
00063 int  v1190B_AcqModeRead(uint16_t *pbase);
00064 int  v1190B_ContinuousSet(uint16_t *pbase);
00065 int  v1190_GeoWrite(WORD *pbase, int geo);
00066 int  v1190_Setup(uint16_t *pbase, int mode);
00067 int  v1190_Status(uint16_t *pbase);
00068 void v1190_SetEdgeDetection(uint16_t *pbase,int enableLeading,int enableTrailing);
00069 
00070 #endif
00071 /* end */

Midas DOC Version 3.0.0 ---- PSI Stefan Ritt ----
Contributions: Pierre-Andre Amaudruz - Sergio Ballestrero - Suzannah Daviel - Doxygen - Peter Green - Qing Gu - Greg Hackman - Gertjan Hofman - Paul Knowles - Exaos Lee - Rudi Meier - Glenn Moloney - Dave Morris - John M O'Donnell - Konstantin Olchanski - Renee Poutissou - Tamsen Schurman - Andreas Suter - Jan M.Wouters - Piotr Adam Zolnierczuk