メインページ   モジュール   クラス階層   アルファベット順一覧   構成   ファイル一覧   構成メンバ   ファイルメンバ   関連ページ    

TVmeRpv130Module.hh

解説を見る。
00001 // =====================================================================
00021 // =====================================================================
00022 #ifndef __TVMERPV130MODULE_HH
00023 #define __TVMERPV130MODULE_HH
00024 
00025 #include "Tglobals.h"
00026 #include "TVmeModule.hh"
00027 
00028 class TDataElement;
00029 
00030 
00050 class TVmeRpv130Module
00051   : public TVmeModule
00052 {
00053 
00054   private:
00055     enum
00056     {
00057       LATCH1 = 0x00,
00058       LATCH2 = 0x02,
00059       RSFF = 0x04,
00060       THROUGH = 0x06,
00061       PULSE = 0x08,
00062       LEVEL = 0x0a,
00063       CSR1 = 0x0c,
00064       CSR2 = 0x0e
00065     };
00066 
00067   public:
00068     enum
00069     {
00070       tReadoutWithLatch1,
00071       tReadoutWithLatch2,
00072       tReadoutWithRSFF,
00073       tReadoutWithThrough
00074     };
00075 
00076   private:
00077     Tint theReadoutMode;
00078     Tint theLevelStatus;
00079 
00080   public:
00081     // should be 1 channel module
00082     TVmeRpv130Module( Toff_t offset, Tint mapsize = 0x1000, Tint nch = 1 );
00083     TVmeRpv130Module( const TVmeRpv130Module& right );
00084     ~TVmeRpv130Module();
00085 
00086   public:
00087     Tint GetReadoutMode() const;
00088     Tvoid SetReadoutMode( Tint readmode );
00089     Tint GetLevelStatus() const;
00090     Tvoid SetLevelStatus( Tint status );
00091 
00092   public:
00093     const TVmeRpv130Module& operator=( const TVmeRpv130Module& right );
00094     Tbool operator==( const TVmeRpv130Module& right ) const;
00095     Tbool operator!=( const TVmeRpv130Module& right ) const;
00096 
00097   public:
00098     Tint Clear();
00099     Tint Update();
00100     Tint Initialize();
00101     Tvoid FillData( TDataElement& element, Tint channel );
00102 
00103   public:
00104     Tvoid Pulse();
00105     Tvoid Pulse( Tint pattern );
00106 
00107     // NIM Signal
00108     // -xxV: 1, 0V: 0
00109     // Up -> 1, Down -> 0
00110     Tvoid Level();
00111     Tvoid Level( Tint pattern );
00112     Tvoid LevelUp();
00113     Tvoid LevelUp( Tint channel );
00114     Tvoid LevelDown();
00115     Tvoid LevelDown( Tint channel );
00116     Tvoid Enable();
00117     Tvoid Disable();
00118     TUshort Read();
00119 
00120 };
00121 
00122 inline Tint TVmeRpv130Module::GetReadoutMode() const
00123 {
00124   return theReadoutMode;
00125 }
00126 
00127 inline Tvoid TVmeRpv130Module::SetReadoutMode( Tint readmode )
00128 {
00129   theReadoutMode = readmode;
00130   return;
00131 }
00132 
00133 inline Tint TVmeRpv130Module::GetLevelStatus() const
00134 {
00135   return theLevelStatus;
00136 }
00137 
00138 inline Tvoid TVmeRpv130Module::SetLevelStatus( Tint status )
00139 {
00140   status &= 0x00ff;
00141   theLevelStatus = status;
00142   return;
00143 }
00144 
00145 #endif

CLDAQ - a Class Library for Data AcQuisition (Version 1.11.0)
Go IWAI <goiwai@users.sourceforge.jp>