\doxysection{RACH channel coding} \label{group__rach}\index{RACH channel coding@{RACH channel coding}} \doxysubsection*{Files} \begin{DoxyCompactItemize} \item file \textbf{ rach.\+h} \begin{DoxyCompactList}\small\item\em Osmocom GMR-\/1 RACH channel coding header. \end{DoxyCompactList}\item file \textbf{ rach.\+c} \begin{DoxyCompactList}\small\item\em Osmocom GMR-\/1 RACH channel coding implementation. \end{DoxyCompactList}\end{DoxyCompactItemize} \doxysubsection*{Functions} \begin{DoxyCompactItemize} \item void \textbf{ gmr1\+\_\+rach\+\_\+encode} (\textbf{ ubit\+\_\+t} $\ast$bits\+\_\+e, const uint8\+\_\+t $\ast$rach, uint8\+\_\+t sb\+\_\+mask) \begin{DoxyCompactList}\small\item\em Stateless GMR-\/1 RACH channel coder. \end{DoxyCompactList}\item int \textbf{ gmr1\+\_\+rach\+\_\+decode} (uint8\+\_\+t $\ast$rach, const \textbf{ sbit\+\_\+t} $\ast$bits\+\_\+e, uint8\+\_\+t sb\+\_\+mask, int $\ast$conv\+\_\+rv, int $\ast$crc\+\_\+rv) \begin{DoxyCompactList}\small\item\em Stateless GMR-\/1 RACH channel decoder. \end{DoxyCompactList}\end{DoxyCompactItemize} \doxysubsection{Detailed Description} \doxysubsection{Function Documentation} \mbox{\label{group__rach_ga4e3f0c261d715b618e188dd5d2a14391}} \index{RACH channel coding@{RACH channel coding}!gmr1\_rach\_decode@{gmr1\_rach\_decode}} \index{gmr1\_rach\_decode@{gmr1\_rach\_decode}!RACH channel coding@{RACH channel coding}} \doxysubsubsection{gmr1\_rach\_decode()} {\footnotesize\ttfamily int gmr1\+\_\+rach\+\_\+decode (\begin{DoxyParamCaption}\item[{uint8\+\_\+t $\ast$}]{rach, }\item[{const \textbf{ sbit\+\_\+t} $\ast$}]{bits\+\_\+e, }\item[{uint8\+\_\+t}]{sb\+\_\+mask, }\item[{int $\ast$}]{conv\+\_\+rv, }\item[{int $\ast$}]{crc\+\_\+rv }\end{DoxyParamCaption})} Stateless GMR-\/1 RACH channel decoder. \begin{DoxyParams}[1]{Parameters} \mbox{\texttt{ out}} & {\em rach} & RACH packet data (2 class-\/1 bytes, 16 class-\/2 bytes) \\ \hline \mbox{\texttt{ in}} & {\em bits\+\_\+e} & Data bits of a burst \\ \hline \mbox{\texttt{ in}} & {\em sb\+\_\+mask} & RACH SB Mask value (see GMR-\/1 04.\+008) \\ \hline \mbox{\texttt{ out}} & {\em conv\+\_\+rv} & Return of the convolutional decode (can be NULL) \\ \hline \mbox{\texttt{ out}} & {\em crc\+\_\+rv} & Return array of the 2 CRC checks (can be NULL) \\ \hline \end{DoxyParams} \begin{DoxyReturn}{Returns} 0 if all CRC check pass, any other value for fail. \end{DoxyReturn} RACH data is 18 bytes long (2 class-\/1, 16 class-\/2), and bits\+\_\+e is a 494 soft bits array unmapped from a RACH burst. References \textbf{ gmr1\+\_\+deinterleave\+\_\+intra()}, \textbf{ gmr1\+\_\+scramble\+\_\+sbit()}, and \textbf{ osmo\+\_\+conv\+\_\+decode()}. \mbox{\label{group__rach_gaa55acd1e1d248c2b34a97af389c69e90}} \index{RACH channel coding@{RACH channel coding}!gmr1\_rach\_encode@{gmr1\_rach\_encode}} \index{gmr1\_rach\_encode@{gmr1\_rach\_encode}!RACH channel coding@{RACH channel coding}} \doxysubsubsection{gmr1\_rach\_encode()} {\footnotesize\ttfamily void gmr1\+\_\+rach\+\_\+encode (\begin{DoxyParamCaption}\item[{\textbf{ ubit\+\_\+t} $\ast$}]{bits\+\_\+e, }\item[{const uint8\+\_\+t $\ast$}]{rach, }\item[{uint8\+\_\+t}]{sb\+\_\+mask }\end{DoxyParamCaption})} Stateless GMR-\/1 RACH channel coder. \begin{DoxyParams}[1]{Parameters} \mbox{\texttt{ out}} & {\em bits\+\_\+e} & Data bits of a burst \\ \hline \mbox{\texttt{ in}} & {\em rach} & RACH packet data (2 class-\/1 bytes, 16 class-\/2 bytes) \\ \hline \mbox{\texttt{ in}} & {\em sb\+\_\+mask} & RACH SB Mask value (see GMR-\/1 04.\+008)\\ \hline \end{DoxyParams} RACH data is 18 bytes long (2 class-\/1, 16 class-\/2), and bits\+\_\+e is a 494 hard bits array to be mapped on a RACH burst. References \textbf{ gmr1\+\_\+crc12}, \textbf{ gmr1\+\_\+crc8}, \textbf{ osmo\+\_\+conv\+\_\+encode()}, \textbf{ osmo\+\_\+crc16gen\+\_\+set\+\_\+bits()}, \textbf{ osmo\+\_\+crc8gen\+\_\+set\+\_\+bits()}, and \textbf{ osmo\+\_\+pbit2ubit\+\_\+ext()}.