\section{eiger\-Detector Class Reference}
\label{classeigerDetector}\index{eigerDetector@{eigerDetector}}
This is class contains all eiger specific functionalities.  


{\tt \#include $<$eiger\-Detector.h$>$}

Inheritance diagram for eiger\-Detector::\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[height=2cm]{classeigerDetector}
\end{center}
\end{figure}
\subsection*{Public Member Functions}
\begin{CompactItemize}
\item 
\bf{eiger\-Detector} (int id=0)
\item 
\bf{$\sim$eiger\-Detector} ()
\item 
\bf{sls\_\-detector\_\-module} $\ast$ \bf{read\-Trim\-File} (string fname, \bf{sls\_\-detector\_\-module} $\ast$my\-Mod=NULL)
\item 
int \bf{write\-Trim\-File} (string fname, \bf{sls\_\-detector\_\-module} mod)
\item 
int \bf{write\-Trim\-File} (string fname, int imod)
\item 
int \bf{write\-Data\-File} (string fname, float $\ast$data, float $\ast$err=NULL, float $\ast$ang=NULL, char dataformat='f', int nch=-1)
\item 
int \bf{write\-Data\-File} (string fname, int $\ast$data)
\item 
int \bf{read\-Data\-File} (string fname, float $\ast$data, float $\ast$err=NULL, float $\ast$ang=NULL, char dataformat='f', int nch=0)
\item 
int \bf{read\-Data\-File} (string fname, int $\ast$data)
\item 
int \bf{read\-Calibration\-File} (string fname, float \&gain, float \&offset)
\item 
int \bf{write\-Calibration\-File} (string fname, float gain, float offset)
\item 
float $\ast$ \bf{decode\-Data} (int $\ast$datain)
\end{CompactItemize}


\subsection{Detailed Description}
This is class contains all eiger specific functionalities. 

The \doxyref{mythen\-Detector}{p.}{classmythenDetector} class contains the functions specific to the eiger detector

\begin{Desc}
\item[Author:]Anna Bergamaschi \end{Desc}
\begin{Desc}
\item[Version:]0.1alpha (any string) \end{Desc}




\subsection{Constructor \& Destructor Documentation}
\index{eigerDetector@{eiger\-Detector}!eigerDetector@{eigerDetector}}
\index{eigerDetector@{eigerDetector}!eigerDetector@{eiger\-Detector}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}eiger\-Detector::eiger\-Detector (int {\em id} = {\tt 0})}\label{classeigerDetector_591261cd5af00795657b44ee2681ced3}


(default) constructor

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em id}]is the detector index which is needed to define the shared memory id. Different physical detectors should have different IDs in order to work independently \end{description}
\end{Desc}
\index{eigerDetector@{eiger\-Detector}!~eigerDetector@{$\sim$eigerDetector}}
\index{~eigerDetector@{$\sim$eigerDetector}!eigerDetector@{eiger\-Detector}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}eiger\-Detector::$\sim$eiger\-Detector ()\hspace{0.3cm}{\tt  [inline]}}\label{classeigerDetector_aa968c7588fb7200a8764a08196ac549}


destructor 

\subsection{Member Function Documentation}
\index{eigerDetector@{eiger\-Detector}!decodeData@{decodeData}}
\index{decodeData@{decodeData}!eigerDetector@{eiger\-Detector}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}float$\ast$ eiger\-Detector::decode\-Data (int $\ast$ {\em datain})}\label{classeigerDetector_3e0573baf38c37818c7769fb351010b3}


decode data from the detector converting them to an array of floats, one for each channle \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em datain}]data from the detector \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]pointer to a float array with a data per channel \end{Desc}


Reimplemented from \bf{sls\-Detector} \doxyref{p.}{classslsDetector_937d257464bade6dc6d3ab42c86843ba}.\index{eigerDetector@{eiger\-Detector}!readCalibrationFile@{readCalibrationFile}}
\index{readCalibrationFile@{readCalibrationFile}!eigerDetector@{eiger\-Detector}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int eiger\-Detector::read\-Calibration\-File (string {\em fname}, float \& {\em gain}, float \& {\em offset})}\label{classeigerDetector_6b1b4b5328a5d8c423e9a7a8a950028f}


int \doxyref{read\-Calibration\-File(string fname, float \&gain, float \&offset)}{p.}{classeigerDetector_6b1b4b5328a5d8c423e9a7a8a950028f};

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em fname}]file to be read \item[{\em gain}]reference to the gain variable  reference to the offset variable \end{description}
\end{Desc}
\begin{Desc}
\item[See also:]\doxyref{shared\-Sls\-Detector}{p.}{classslsDetector_2dd6bff7d94ab8005c2797152b19264e} \end{Desc}


Reimplemented from \bf{sls\-Detector} \doxyref{p.}{classslsDetector_9305060e7499cfcabac23b99c884b92b}.\index{eigerDetector@{eiger\-Detector}!readDataFile@{readDataFile}}
\index{readDataFile@{readDataFile}!eigerDetector@{eiger\-Detector}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int eiger\-Detector::read\-Data\-File (string {\em fname}, int $\ast$ {\em data})}\label{classeigerDetector_a6afa206101506d7f95d1ec835fbf843}


reads a data file \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em name}]of the file to be read \item[{\em data}]array of data values \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]OK or FAIL if it could not read the file or data=NULL \end{Desc}


Reimplemented from \bf{sls\-Detector} \doxyref{p.}{classslsDetector_0d27017bc1140cc9da3e797f03848f2e}.\index{eigerDetector@{eiger\-Detector}!readDataFile@{readDataFile}}
\index{readDataFile@{readDataFile}!eigerDetector@{eiger\-Detector}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int eiger\-Detector::read\-Data\-File (string {\em fname}, float $\ast$ {\em data}, float $\ast$ {\em err} = {\tt NULL}, float $\ast$ {\em ang} = {\tt NULL}, char {\em dataformat} = {\tt 'f'}, int {\em nch} = {\tt 0})}\label{classeigerDetector_4d0b7da609b9a0457656bfc8cf0a7997}


reads a data file \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em name}]of the file to be read \item[{\em data}]array of data values to be filled \item[{\em err}]array of arrors on the data. If NULL no errors are expected on the file\item[{\em ang}]array of angular values. If NULL data are expected in the form chan-val(-err) otherwise ang-val(-err) \item[{\em dataformat}]format of the data: can be 'i' integer or 'f' float (default) \item[{\em nch}]number of channels to be written to file. if $<$=0 defaults to the number of installed channels of the detector \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]OK or FAIL if it could not read the file or data=NULL \end{Desc}


Reimplemented from \bf{sls\-Detector} \doxyref{p.}{classslsDetector_ffd62fa6a3487693316209ea71502b4b}.\index{eigerDetector@{eiger\-Detector}!readTrimFile@{readTrimFile}}
\index{readTrimFile@{readTrimFile}!eigerDetector@{eiger\-Detector}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}\bf{sls\_\-detector\_\-module}$\ast$ eiger\-Detector::read\-Trim\-File (string {\em fname}, \bf{sls\_\-detector\_\-module} $\ast$ {\em my\-Mod} = {\tt NULL})}\label{classeigerDetector_f24af0459e8eb45c1bc9c68a870e5094}


reads a trim file \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em fname}]name of the file to be read \item[{\em my\-Mod}]pointer to the module structure which has to be set. \par
 If it is NULL a new module structure will be created \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]the pointer to my\-Mod or NULL if reading the file failed \end{Desc}


Reimplemented from \bf{sls\-Detector} \doxyref{p.}{classslsDetector_e84b8a7a2b27db3f89a98f9f8a81efca}.\index{eigerDetector@{eiger\-Detector}!writeCalibrationFile@{writeCalibrationFile}}
\index{writeCalibrationFile@{writeCalibrationFile}!eigerDetector@{eiger\-Detector}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int eiger\-Detector::write\-Calibration\-File (string {\em fname}, float {\em gain}, float {\em offset})}\label{classeigerDetector_d5fbecfcc46cb151160c6011aa8e33b2}


writes a clibration file \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em fname}]file to be written \item[{\em gain}]\item[{\em offset}]\end{description}
\end{Desc}
\begin{Desc}
\item[See also:]\doxyref{shared\-Sls\-Detector}{p.}{classslsDetector_2dd6bff7d94ab8005c2797152b19264e} \end{Desc}


Reimplemented from \bf{sls\-Detector} \doxyref{p.}{classslsDetector_8eb676a1ab6ef35601ba5cae942ba380}.\index{eigerDetector@{eiger\-Detector}!writeDataFile@{writeDataFile}}
\index{writeDataFile@{writeDataFile}!eigerDetector@{eiger\-Detector}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int eiger\-Detector::write\-Data\-File (string {\em fname}, int $\ast$ {\em data})}\label{classeigerDetector_68a740d5e43fcdb00c57f401666c0856}


writes a data file \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em name}]of the file to be written \item[{\em data}]array of data values \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]OK or FAIL if it could not write the file or data=NULL \end{Desc}


Reimplemented from \bf{sls\-Detector} \doxyref{p.}{classslsDetector_3e1a8e49fbfb34a54381452abc8b5258}.\index{eigerDetector@{eiger\-Detector}!writeDataFile@{writeDataFile}}
\index{writeDataFile@{writeDataFile}!eigerDetector@{eiger\-Detector}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int eiger\-Detector::write\-Data\-File (string {\em fname}, float $\ast$ {\em data}, float $\ast$ {\em err} = {\tt NULL}, float $\ast$ {\em ang} = {\tt NULL}, char {\em dataformat} = {\tt 'f'}, int {\em nch} = {\tt -1})}\label{classeigerDetector_5ad2bf5b10d17e8c4ad7ae6e81e647e0}


writes a data file \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em name}]of the file to be written \item[{\em data}]array of data values \item[{\em err}]array of arrors on the data. If NULL no errors will be written\item[{\em ang}]array of angular values. If NULL data will be in the form chan-val(-err) otherwise ang-val(-err) \item[{\em dataformat}]format of the data: can be 'i' integer or 'f' float (default) \item[{\em nch}]number of channels to be written to file. if -1 defaults to the number of installed channels of the detector \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]OK or FAIL if it could not write the file or data=NULL \end{Desc}


Reimplemented from \bf{sls\-Detector} \doxyref{p.}{classslsDetector_889c060afb5693830ca2be4fc6a5442c}.\index{eigerDetector@{eiger\-Detector}!writeTrimFile@{writeTrimFile}}
\index{writeTrimFile@{writeTrimFile}!eigerDetector@{eiger\-Detector}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int eiger\-Detector::write\-Trim\-File (string {\em fname}, int {\em imod})}\label{classeigerDetector_df3a0dff0fc3111e10af0363bdd15a6a}


writes a trim file for module number imod - the values will be read from the current detector structure \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em fname}]name of the file to be written \item[{\em imod}]module number \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]OK or FAIL if the file could not be written \end{Desc}
\begin{Desc}
\item[See also:]\doxyref{sls\_\-detector\_\-module}{p.}{structsls__detector__module} \doxyref{shared\-Sls\-Detector}{p.}{classslsDetector_2dd6bff7d94ab8005c2797152b19264e} \end{Desc}


Reimplemented from \bf{sls\-Detector} \doxyref{p.}{classslsDetector_afe675432bf8e5dcb47774da3cc81106}.\index{eigerDetector@{eiger\-Detector}!writeTrimFile@{writeTrimFile}}
\index{writeTrimFile@{writeTrimFile}!eigerDetector@{eiger\-Detector}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int eiger\-Detector::write\-Trim\-File (string {\em fname}, \bf{sls\_\-detector\_\-module} {\em mod})}\label{classeigerDetector_8380366bf7112021c49be8e6f29f18d8}


writes a trim file \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em fname}]name of the file to be written \item[{\em mod}]module structure which has to be written to file \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]OK or FAIL if the file could not be written\end{Desc}
\begin{Desc}
\item[See also:]\doxyref{sls\_\-detector\_\-module}{p.}{structsls__detector__module} \end{Desc}


Reimplemented from \bf{sls\-Detector} \doxyref{p.}{classslsDetector_9cbb1f97b8e48bd4b108a2dfa992c6af}.

The documentation for this class was generated from the following file:\begin{CompactItemize}
\item 
eiger\-Detector/\bf{eiger\-Detector.h}\end{CompactItemize}
