fdhwlib
2.0.25
|
00001 /*************************************************************************** 00002 pbusversion.h - description 00003 00004 begin : Mon Jan 15 2001 00005 copyright : (C) 2001 by A Kopmann 00006 email : kopmann@hpe.fzk.de 00007 status : 00008 test : 00009 history : 00010 ***************************************************************************/ 00011 00012 00013 #ifndef PBUSVERSION_H 00014 #define PBUSVERSION_H 00015 00016 #include <cstdio> 00017 #include <string> 00018 00019 #include <Pbus/Pbus.h> 00020 00021 #ifdef PBUS_VCLASS 00022 00023 #if defined (PBUS_DIRECT) || (PBUS_TEST) 00024 #include <Pbus/microenableversion.h> 00025 #endif 00026 #include <Pbus/pbusdaemonversion.h> 00027 00028 class Pbus; 00029 #if defined (PBUS_DIRECT) || (PBUS_TEST) 00030 class MicroEnableVersion; 00031 #endif 00032 class PbusDaemonVersion; 00033 00046 class PbusVersion { 00047 public: 00048 PbusVersion(); 00049 ~PbusVersion(); 00050 00051 void display(FILE *fout); 00052 int check(char *ini="FE.ini"); 00053 00054 const char * get(); 00055 00056 const char * getMode(); 00057 00058 #if defined (PBUS_DIRECT) || (PBUS_TEST) 00059 void updateMicroEnable(microenable *board,fpga_design *design); 00060 #endif 00061 void updatePbusd(unsigned long *data, int len); 00062 00063 #if defined (PBUS_DIRECT) || (PBUS_TEST) 00064 MicroEnableVersion *menable; 00065 #endif 00066 PbusDaemonVersion *pbusd; 00067 00068 int length(); 00069 00070 int copyTo(unsigned long *data, int n); 00071 00072 int copyFrom(unsigned long *data, int n); 00073 00074 00075 private: 00076 string version; 00077 00078 int mode; 00079 00080 bool mounted; 00081 00082 }; 00083 00084 00085 #endif 00086 00087 #endif