\hypertarget{gGTCC_8h}{
\section{g\-GTCC.h File Reference}
\label{gGTCC_8h}\index{gGTCC.h@{gGTCC.h}}
}
command/response methods for the GTCC  


\subsection*{Functions}
\begin{CompactItemize}
\item 
int \hyperlink{gGTCC_8h_a0}{g\-GTCCcmd} (\hyperlink{struct__gtem}{gtem\-Handle} gt, unsigned short tem\-Addr, unsigned short gtcc\-Addr, unsigned short opcode)
\begin{CompactList}\small\item\em Sends a dataless command to the TEM address. \item\end{CompactList}\item 
int \hyperlink{gGTCC_8h_a1}{g\-GTCCload} (\hyperlink{struct__gtem}{gtem\-Handle} gt, unsigned short tem\-Addr, unsigned short gtcc\-Addr, unsigned short reg\-Id, unsigned int val)
\begin{CompactList}\small\item\em Loads a register with value. \item\end{CompactList}\item 
int \hyperlink{gGTCC_8h_a2}{g\-GTCCread} (\hyperlink{struct__gtem}{gtem\-Handle} gt, unsigned short tem\-Addr, unsigned short gtcc\-Addr, unsigned short reg\-Id, unsigned int $\ast$val)
\begin{CompactList}\small\item\em Reads a register returing value in {\em val\/}. \item\end{CompactList}\end{CompactItemize}


\subsection{Detailed Description}
command/response methods for the GTCC 

\begin{Desc}
\item[Author:]Curt Brune -- \href{mailto:curt@slac.stanford.edu}{\tt curt@slac.stanford.edu}\end{Desc}


\subsection{Function Documentation}
\hypertarget{gGTCC_8h_a0}{
\index{gGTCC.h@{g\-GTCC.h}!gGTCCcmd@{gGTCCcmd}}
\index{gGTCCcmd@{gGTCCcmd}!gGTCC.h@{g\-GTCC.h}}
\subsubsection[gGTCCcmd]{\setlength{\rightskip}{0pt plus 5cm}int g\-GTCCcmd (\hyperlink{struct__gtem}{gtem\-Handle} {\em gt}, unsigned short {\em tem\-Addr}, unsigned short {\em gtcc\-Addr}, unsigned short {\em opcode})}}
\label{gGTCC_8h_a0}


Sends a dataless command to the TEM address. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em gt}]gtem\-Handle for TEM \item[{\em tem\-Addr}]TEM address of command \item[{\em gtcc\-Addr}]GTCC address \item[{\em opcode}]opcode of command to send \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]G\_\-OK on success\end{Desc}
Sends the dataless command specified by {\em opcode\/} to the TEM address specified by {\em tem\-Addr\/}. \hypertarget{gGTCC_8h_a1}{
\index{gGTCC.h@{g\-GTCC.h}!gGTCCload@{gGTCCload}}
\index{gGTCCload@{gGTCCload}!gGTCC.h@{g\-GTCC.h}}
\subsubsection[gGTCCload]{\setlength{\rightskip}{0pt plus 5cm}int g\-GTCCload (\hyperlink{struct__gtem}{gtem\-Handle} {\em gt}, unsigned short {\em tem\-Addr}, unsigned short {\em gtcc\-Addr}, unsigned short {\em reg}, unsigned int {\em value})}}
\label{gGTCC_8h_a1}


Loads a register with value. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em gt}]gtem\-Handle for TEM \item[{\em tem\-Addr}]TEM address of command \item[{\em gtcc\-Addr}]GTCC address \item[{\em reg}]register of GTCC to load \item[{\em value}]32-bit value to load into GTCC register \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]G\_\-OK on success\end{Desc}
Loads the GTCC register specified by {\em reg\/} with {\em value\/} \hypertarget{gGTCC_8h_a2}{
\index{gGTCC.h@{g\-GTCC.h}!gGTCCread@{gGTCCread}}
\index{gGTCCread@{gGTCCread}!gGTCC.h@{g\-GTCC.h}}
\subsubsection[gGTCCread]{\setlength{\rightskip}{0pt plus 5cm}int g\-GTCCread (\hyperlink{struct__gtem}{gtem\-Handle} {\em gt}, unsigned short {\em tem\-Addr}, unsigned short {\em gtcc\-Addr}, unsigned short {\em reg}, unsigned int $\ast$ {\em val})}}
\label{gGTCC_8h_a2}


Reads a register returing value in {\em val\/}. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em gt}]gtem\-Handle for TEM \item[{\em tem\-Addr}]TEM address of command \item[{\em gtcc\-Addr}]GTCC address \item[{\em reg}]register of GTCC to read \item[{\em val}]pointer to storage to hold the response of the read command \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]G\_\-OK on success\end{Desc}
Reads the GTCC register specified by {\em reg\/}. {\em val\/} is filled on return.

The following error codes are returned when LATp errors occur:

\begin{itemize}
\item GERR\_\-LATP\_\-HEADER\_\-PARITY \item GERR\_\-LATP\_\-CELL\_\-PARITY \item GERR\_\-LATP\_\-TRUNCATE \end{itemize}
