\hypertarget{classutl_1_1spi__i_3_01virtual__tag_01_4}{}\section{utl\+:\+:spi\+\_\+i$<$ virtual\+\_\+tag $>$ Class Template Reference}
\label{classutl_1_1spi__i_3_01virtual__tag_01_4}\index{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}}


A virtual base class implementation.  




{\ttfamily \#include $<$spi.\+h$>$}

Inheritance diagram for utl\+:\+:spi\+\_\+i$<$ virtual\+\_\+tag $>$\+:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[height=2.000000cm]{classutl_1_1spi__i_3_01virtual__tag_01_4}
\end{center}
\end{figure}
\subsection*{Public Types}
\begin{DoxyCompactItemize}
\item 
using \mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_ab539774624977f1f86b98269d01d56ba}{type}} = \mbox{\hyperlink{classutl_1_1spi__i}{spi\+\_\+i}}$<$ \mbox{\hyperlink{structutl_1_1virtual__tag}{virtual\+\_\+tag}} $>$
\begin{DoxyCompactList}\small\item\em Export type as identity meta-\/function. \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Public Member Functions}
\begin{Indent}\textbf{ Get/\+Set functions provided by the interface}\par
\begin{DoxyCompactItemize}
\item 
uint32\+\_\+t \mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_a92a9350f72d3fca45b0900bf2bf5e8d9}{clock}} () const
\item 
void \mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_af168fba0d949aade779a63abf9f4bad2}{clock}} (uint32\+\_\+t c)
\begin{DoxyCompactList}\small\item\em set clock frequency of the bus \end{DoxyCompactList}\end{DoxyCompactItemize}
\end{Indent}
\begin{Indent}\textbf{ I/O functions provided by the interface}\par
\begin{DoxyCompactItemize}
\item 
\mbox{\hyperlink{namespaceutl_a1427cb5a2b13313147a902173b91e3c1}{byte\+\_\+t}} \mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_ac7b587521c1fdc83d32164dcee3c7b40}{tx\+\_\+data}} (\mbox{\hyperlink{namespaceutl_a1427cb5a2b13313147a902173b91e3c1}{byte\+\_\+t}} out)
\item 
\mbox{\hyperlink{namespaceutl_a22cbecb50ee5c1032de66133e96cbac6}{size\+\_\+t}} \mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_a2777c812eb27d7b3d106c55b31819d10}{tx\+\_\+data}} (const \mbox{\hyperlink{namespaceutl_a1427cb5a2b13313147a902173b91e3c1}{byte\+\_\+t}} $\ast$out, \mbox{\hyperlink{namespaceutl_a1427cb5a2b13313147a902173b91e3c1}{byte\+\_\+t}} $\ast$in, \mbox{\hyperlink{namespaceutl_a22cbecb50ee5c1032de66133e96cbac6}{size\+\_\+t}} n)
\begin{DoxyCompactList}\small\item\em Transmit a number of bytes to the spi bus and read the response. \end{DoxyCompactList}\item 
\mbox{\hyperlink{namespaceutl_a1427cb5a2b13313147a902173b91e3c1}{byte\+\_\+t}} \mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_a8ccd44f6fa97bbfe8cda5595436eb3a7}{rx\+\_\+data}} ()
\item 
\mbox{\hyperlink{namespaceutl_a22cbecb50ee5c1032de66133e96cbac6}{size\+\_\+t}} \mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_a59245cc0d924d160268b6813975a7c5f}{rx\+\_\+data}} (\mbox{\hyperlink{namespaceutl_a1427cb5a2b13313147a902173b91e3c1}{byte\+\_\+t}} $\ast$in, \mbox{\hyperlink{namespaceutl_a22cbecb50ee5c1032de66133e96cbac6}{size\+\_\+t}} n)
\begin{DoxyCompactList}\small\item\em Receive a number of bytes from the spi bus while transmitting 0x\+F\+Fs. \end{DoxyCompactList}\end{DoxyCompactItemize}
\end{Indent}
\subsection*{Object lifetime}
\begin{DoxyCompactItemize}
\item 
\mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_a954d8294026bf4628771e588e8a0eb5e}{spi\+\_\+i}} ()=default
\begin{DoxyCompactList}\small\item\em Allow constructor from derived only. \end{DoxyCompactList}\item 
\mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_a142e481dff89219cab72ec444fc069db}{spi\+\_\+i}} (const \mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_ab539774624977f1f86b98269d01d56ba}{type}} \&)=delete
\begin{DoxyCompactList}\small\item\em No copies. \end{DoxyCompactList}\item 
\mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_ab539774624977f1f86b98269d01d56ba}{type}} \& \mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_aa24dd9ed5e342ab0f27b4ef296516e5b}{operator=}} (const \mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_ab539774624977f1f86b98269d01d56ba}{type}} \&)=delete
\item 
virtual \mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_a7149ebd15799723fe3d2a97566608a19}{$\sim$spi\+\_\+i}} ()=default
\end{DoxyCompactItemize}


\subsection{Detailed Description}
\subsubsection*{template$<$$>$\newline
class utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}

A virtual base class implementation. 


\begin{DoxyParams}{Parameters}
{\em none} & \\
\hline
\end{DoxyParams}


Definition at line 177 of file spi.\+h.



\subsection{Member Typedef Documentation}
\mbox{\Hypertarget{classutl_1_1spi__i_3_01virtual__tag_01_4_ab539774624977f1f86b98269d01d56ba}\label{classutl_1_1spi__i_3_01virtual__tag_01_4_ab539774624977f1f86b98269d01d56ba}} 
\index{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}!type@{type}}
\index{type@{type}!utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}}
\subsubsection{\texorpdfstring{type}{type}}
{\footnotesize\ttfamily using \mbox{\hyperlink{classutl_1_1spi__i}{utl\+::spi\+\_\+i}}$<$ \mbox{\hyperlink{structutl_1_1virtual__tag}{virtual\+\_\+tag}} $>$\+::\mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_ab539774624977f1f86b98269d01d56ba}{type}} =  \mbox{\hyperlink{classutl_1_1spi__i}{spi\+\_\+i}}$<$\mbox{\hyperlink{structutl_1_1virtual__tag}{virtual\+\_\+tag}}$>$}



Export type as identity meta-\/function. 



Definition at line 179 of file spi.\+h.



\subsection{Constructor \& Destructor Documentation}
\mbox{\Hypertarget{classutl_1_1spi__i_3_01virtual__tag_01_4_a954d8294026bf4628771e588e8a0eb5e}\label{classutl_1_1spi__i_3_01virtual__tag_01_4_a954d8294026bf4628771e588e8a0eb5e}} 
\index{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}!spi\+\_\+i@{spi\+\_\+i}}
\index{spi\+\_\+i@{spi\+\_\+i}!utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}}
\subsubsection{\texorpdfstring{spi\+\_\+i()}{spi\_i()}\hspace{0.1cm}{\footnotesize\ttfamily [1/2]}}
{\footnotesize\ttfamily \mbox{\hyperlink{classutl_1_1spi__i}{utl\+::spi\+\_\+i}}$<$ \mbox{\hyperlink{structutl_1_1virtual__tag}{virtual\+\_\+tag}} $>$\+::\mbox{\hyperlink{classutl_1_1spi__i}{spi\+\_\+i}} (\begin{DoxyParamCaption}{ }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [protected]}, {\ttfamily [default]}}



Allow constructor from derived only. 

\mbox{\Hypertarget{classutl_1_1spi__i_3_01virtual__tag_01_4_a142e481dff89219cab72ec444fc069db}\label{classutl_1_1spi__i_3_01virtual__tag_01_4_a142e481dff89219cab72ec444fc069db}} 
\index{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}!spi\+\_\+i@{spi\+\_\+i}}
\index{spi\+\_\+i@{spi\+\_\+i}!utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}}
\subsubsection{\texorpdfstring{spi\+\_\+i()}{spi\_i()}\hspace{0.1cm}{\footnotesize\ttfamily [2/2]}}
{\footnotesize\ttfamily \mbox{\hyperlink{classutl_1_1spi__i}{utl\+::spi\+\_\+i}}$<$ \mbox{\hyperlink{structutl_1_1virtual__tag}{virtual\+\_\+tag}} $>$\+::\mbox{\hyperlink{classutl_1_1spi__i}{spi\+\_\+i}} (\begin{DoxyParamCaption}\item[{const \mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_ab539774624977f1f86b98269d01d56ba}{type}} \&}]{ }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [protected]}, {\ttfamily [delete]}}



No copies. 

\mbox{\Hypertarget{classutl_1_1spi__i_3_01virtual__tag_01_4_a7149ebd15799723fe3d2a97566608a19}\label{classutl_1_1spi__i_3_01virtual__tag_01_4_a7149ebd15799723fe3d2a97566608a19}} 
\index{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}!````~spi\+\_\+i@{$\sim$spi\+\_\+i}}
\index{````~spi\+\_\+i@{$\sim$spi\+\_\+i}!utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}}
\subsubsection{\texorpdfstring{$\sim$spi\+\_\+i()}{~spi\_i()}}
{\footnotesize\ttfamily virtual \mbox{\hyperlink{classutl_1_1spi__i}{utl\+::spi\+\_\+i}}$<$ \mbox{\hyperlink{structutl_1_1virtual__tag}{virtual\+\_\+tag}} $>$\+::$\sim$\mbox{\hyperlink{classutl_1_1spi__i}{spi\+\_\+i}} (\begin{DoxyParamCaption}{ }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [virtual]}, {\ttfamily [default]}}

Virtual default destructor 

\subsection{Member Function Documentation}
\mbox{\Hypertarget{classutl_1_1spi__i_3_01virtual__tag_01_4_a92a9350f72d3fca45b0900bf2bf5e8d9}\label{classutl_1_1spi__i_3_01virtual__tag_01_4_a92a9350f72d3fca45b0900bf2bf5e8d9}} 
\index{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}!clock@{clock}}
\index{clock@{clock}!utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}}
\subsubsection{\texorpdfstring{clock()}{clock()}\hspace{0.1cm}{\footnotesize\ttfamily [1/2]}}
{\footnotesize\ttfamily uint32\+\_\+t \mbox{\hyperlink{classutl_1_1spi__i}{utl\+::spi\+\_\+i}}$<$ \mbox{\hyperlink{structutl_1_1virtual__tag}{virtual\+\_\+tag}} $>$\+::clock (\begin{DoxyParamCaption}{ }\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}

\begin{DoxyReturn}{Returns}
clock frequency of the bus 
\end{DoxyReturn}


Definition at line 208 of file spi.\+h.

\mbox{\Hypertarget{classutl_1_1spi__i_3_01virtual__tag_01_4_af168fba0d949aade779a63abf9f4bad2}\label{classutl_1_1spi__i_3_01virtual__tag_01_4_af168fba0d949aade779a63abf9f4bad2}} 
\index{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}!clock@{clock}}
\index{clock@{clock}!utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}}
\subsubsection{\texorpdfstring{clock()}{clock()}\hspace{0.1cm}{\footnotesize\ttfamily [2/2]}}
{\footnotesize\ttfamily void \mbox{\hyperlink{classutl_1_1spi__i}{utl\+::spi\+\_\+i}}$<$ \mbox{\hyperlink{structutl_1_1virtual__tag}{virtual\+\_\+tag}} $>$\+::clock (\begin{DoxyParamCaption}\item[{uint32\+\_\+t}]{c }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}}



set clock frequency of the bus 



Definition at line 209 of file spi.\+h.

\mbox{\Hypertarget{classutl_1_1spi__i_3_01virtual__tag_01_4_aa24dd9ed5e342ab0f27b4ef296516e5b}\label{classutl_1_1spi__i_3_01virtual__tag_01_4_aa24dd9ed5e342ab0f27b4ef296516e5b}} 
\index{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}!operator=@{operator=}}
\index{operator=@{operator=}!utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}}
\subsubsection{\texorpdfstring{operator=()}{operator=()}}
{\footnotesize\ttfamily \mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_ab539774624977f1f86b98269d01d56ba}{type}}\& \mbox{\hyperlink{classutl_1_1spi__i}{utl\+::spi\+\_\+i}}$<$ \mbox{\hyperlink{structutl_1_1virtual__tag}{virtual\+\_\+tag}} $>$\+::operator= (\begin{DoxyParamCaption}\item[{const \mbox{\hyperlink{classutl_1_1spi__i_3_01virtual__tag_01_4_ab539774624977f1f86b98269d01d56ba}{type}} \&}]{ }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [protected]}, {\ttfamily [delete]}}

\mbox{\Hypertarget{classutl_1_1spi__i_3_01virtual__tag_01_4_a8ccd44f6fa97bbfe8cda5595436eb3a7}\label{classutl_1_1spi__i_3_01virtual__tag_01_4_a8ccd44f6fa97bbfe8cda5595436eb3a7}} 
\index{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}!rx\+\_\+data@{rx\+\_\+data}}
\index{rx\+\_\+data@{rx\+\_\+data}!utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}}
\subsubsection{\texorpdfstring{rx\+\_\+data()}{rx\_data()}\hspace{0.1cm}{\footnotesize\ttfamily [1/2]}}
{\footnotesize\ttfamily \mbox{\hyperlink{namespaceutl_a1427cb5a2b13313147a902173b91e3c1}{byte\+\_\+t}} \mbox{\hyperlink{classutl_1_1spi__i}{utl\+::spi\+\_\+i}}$<$ \mbox{\hyperlink{structutl_1_1virtual__tag}{virtual\+\_\+tag}} $>$\+::rx\+\_\+data (\begin{DoxyParamCaption}{ }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}}

Receive a byte from spi bus while transmitting 0x\+FF 

Definition at line 235 of file spi.\+h.

\mbox{\Hypertarget{classutl_1_1spi__i_3_01virtual__tag_01_4_a59245cc0d924d160268b6813975a7c5f}\label{classutl_1_1spi__i_3_01virtual__tag_01_4_a59245cc0d924d160268b6813975a7c5f}} 
\index{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}!rx\+\_\+data@{rx\+\_\+data}}
\index{rx\+\_\+data@{rx\+\_\+data}!utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}}
\subsubsection{\texorpdfstring{rx\+\_\+data()}{rx\_data()}\hspace{0.1cm}{\footnotesize\ttfamily [2/2]}}
{\footnotesize\ttfamily \mbox{\hyperlink{namespaceutl_a22cbecb50ee5c1032de66133e96cbac6}{size\+\_\+t}} \mbox{\hyperlink{classutl_1_1spi__i}{utl\+::spi\+\_\+i}}$<$ \mbox{\hyperlink{structutl_1_1virtual__tag}{virtual\+\_\+tag}} $>$\+::rx\+\_\+data (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{namespaceutl_a1427cb5a2b13313147a902173b91e3c1}{byte\+\_\+t}} $\ast$}]{in,  }\item[{\mbox{\hyperlink{namespaceutl_a22cbecb50ee5c1032de66133e96cbac6}{size\+\_\+t}}}]{n }\end{DoxyParamCaption})}



Receive a number of bytes from the spi bus while transmitting 0x\+F\+Fs. 


\begin{DoxyParams}{Parameters}
{\em in} & Pointer to buffer to store the data \\
\hline
{\em n} & The number of bytes to read \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
The number of received bytes. 
\end{DoxyReturn}


Definition at line 270 of file spi.\+h.

\mbox{\Hypertarget{classutl_1_1spi__i_3_01virtual__tag_01_4_ac7b587521c1fdc83d32164dcee3c7b40}\label{classutl_1_1spi__i_3_01virtual__tag_01_4_ac7b587521c1fdc83d32164dcee3c7b40}} 
\index{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}!tx\+\_\+data@{tx\+\_\+data}}
\index{tx\+\_\+data@{tx\+\_\+data}!utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}}
\subsubsection{\texorpdfstring{tx\+\_\+data()}{tx\_data()}\hspace{0.1cm}{\footnotesize\ttfamily [1/2]}}
{\footnotesize\ttfamily \mbox{\hyperlink{namespaceutl_a1427cb5a2b13313147a902173b91e3c1}{byte\+\_\+t}} \mbox{\hyperlink{classutl_1_1spi__i}{utl\+::spi\+\_\+i}}$<$ \mbox{\hyperlink{structutl_1_1virtual__tag}{virtual\+\_\+tag}} $>$\+::tx\+\_\+data (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{namespaceutl_a1427cb5a2b13313147a902173b91e3c1}{byte\+\_\+t}}}]{out }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}}

Transmit a byte to spi bus and return the response 

Definition at line 220 of file spi.\+h.

\mbox{\Hypertarget{classutl_1_1spi__i_3_01virtual__tag_01_4_a2777c812eb27d7b3d106c55b31819d10}\label{classutl_1_1spi__i_3_01virtual__tag_01_4_a2777c812eb27d7b3d106c55b31819d10}} 
\index{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}!tx\+\_\+data@{tx\+\_\+data}}
\index{tx\+\_\+data@{tx\+\_\+data}!utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$@{utl\+::spi\+\_\+i$<$ virtual\+\_\+tag $>$}}
\subsubsection{\texorpdfstring{tx\+\_\+data()}{tx\_data()}\hspace{0.1cm}{\footnotesize\ttfamily [2/2]}}
{\footnotesize\ttfamily \mbox{\hyperlink{namespaceutl_a22cbecb50ee5c1032de66133e96cbac6}{size\+\_\+t}} \mbox{\hyperlink{classutl_1_1spi__i}{utl\+::spi\+\_\+i}}$<$ \mbox{\hyperlink{structutl_1_1virtual__tag}{virtual\+\_\+tag}} $>$\+::tx\+\_\+data (\begin{DoxyParamCaption}\item[{const \mbox{\hyperlink{namespaceutl_a1427cb5a2b13313147a902173b91e3c1}{byte\+\_\+t}} $\ast$}]{out,  }\item[{\mbox{\hyperlink{namespaceutl_a1427cb5a2b13313147a902173b91e3c1}{byte\+\_\+t}} $\ast$}]{in,  }\item[{\mbox{\hyperlink{namespaceutl_a22cbecb50ee5c1032de66133e96cbac6}{size\+\_\+t}}}]{n }\end{DoxyParamCaption})}



Transmit a number of bytes to the spi bus and read the response. 


\begin{DoxyParams}{Parameters}
{\em out} & Pointer to data to send to the bus \\
\hline
{\em in} & Pointer to buffer to store the data from the bus \\
\hline
{\em n} & The number of bytes to transmit/receive \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
The number of bytes. 
\end{DoxyReturn}


Definition at line 258 of file spi.\+h.



The documentation for this class was generated from the following file\+:\begin{DoxyCompactItemize}
\item 
include/utl/com/\mbox{\hyperlink{spi_8h}{spi.\+h}}\end{DoxyCompactItemize}
