<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">\documentclass[onecolumn,letterpaper,11pt]{article}

%===================================================================
\input{common_latex/common_latex_packages}
\input{common_latex/common_latex_definitions}
\input{common_latex/common_latex_help_format}
%===================================================================

\begin{document}

\begin{labcover}
\labtitle{uSimCurrent: Simulating Drift Effects}
\vspace{0.1in}
\labdate{June 2018}
\vspace{0.1in}
\labauth{Michael Benjamin, mikerb@mit.edu}
\labauth{Department of Mechanical Engineering}
\labauth{MIT, Cambridge MA 02139}
\labtoc{small}
\end{labcover}

\wikidoc{file=IvPTools.USimCurrent}
\wikidoc{bugz=uSimCurrent}
\wikidoc{auth=mikerb@mit.edu}

%=================================================================
\section{Overview}
%=================================================================
\label{sec_util_usc}
\index{uSimCurrent}

The \app{uSimCurrent} MOOS application is a newcomer in the toolbox
and documentation is thin. Nevertheless it has been tested and used
quite a bit and is worth a quick introduction here for those with 
a need for some ability to simulate water current on unmanned vehicles.

\pskip

\app{uSimCurrent} is intended to be used with the \app{uSimMarine}
simulator, by generating drift vectors and publishing them to the
MOOSDB. The \app{uSimMarine} simulator has a generic interface to
accept externally published drift vectors regardless of the source,
written to the variables \mvar{DRIFT\_X}, \mvar{DRIFT\_Y}, and
\mvar{DRIFT\_VECTOR}.  The \app{uSimCurrent} application reads a
provided {\em current field file} containing an association of water
current to positions in the water. On iteration of \app{uSimCurrent},
the vehicle's current position is noted, looked up in the
current-field data structure, and a new drift vector is posted. The
idea is shown in Figure \ref{usc_topology}.

\vspace{0.15in}
\begin{figure}[H]
  \centering 
  \includegraphics[width=0.78\textwidth]{figures/usc_overview.png}
  \caption{{\bf The \aapp{uSimCurrent} utility:} The simulator is
    initialized with a data file describing currents and locations.
    The simulator then repeatedly publishes a current vector based on
    the present vehicle position.}
\label{usc_topology}
\end{figure}
\vspace{0.15in}

%=================================================================
\section{Configuration Parameters for uSimCurrent}
%=================================================================
\index{uSimCurrent!Configuration Parameters}
\index{Configuration Parameters!uSimCurrent}

The following configuration parameters are defined for
\app{uSimCurrent}. A more detailed description is provided in other
parts of this section. Parameters having default values are indicated
so.

\vspace{0.15in}
\begin{listing}{Configuration Parameters for \app{uSimCurrent}}
\label{lst_usc_params}
\renewcommand{\arraystretch}{1.1}
\begin{longtable}{rp{0.72\textwidth}} 

  \pvar{current\_field}: &amp; Name of a file describing a current
  field. \\

  \pvar{current\_field\_active}: &amp; Boolean indicating whether the
  simulator is active. \\

\end{longtable}
\end{listing}

%=================================================================
\section{Publications and Subscriptions for uSimCurrent}
%=================================================================
\index{uSimCurrent!Publications and Subscriptions}
\index{Publications and Subscriptions!uSimCurrent}

The interface for \app{uSimCurrent}, in terms of publications and 
subscriptions, is described below. This same information may also be
obtained from the terminal with:

\begin{consoleverb}
 $ uSimCurrent --interface or -i
\end{consoleverb}

%=================================================================
\subsection{MOOS Variables Published by uSimCurrent}
\label{sec_usc_pubs}

The primary output of uSimCurrent to the MOOSDB is the drift vector
to be consumed by the \app{uSimMarine} application.

\begin{packed_itemize}[2]
\item \mvar{DRIFT\_VECTOR}: drift vector representing the prevailing
  current. See the \app{uSimMarine} documentation.

\item \mvar{USC\_CFIELD\_SUMMARY}: Summary of configured current
  field.

\item \mvar{VIEW\_VECTOR}: Vector objects suitable for rendering in
  GUI applications.

\end{packed_itemize}

%=================================================================
\subsection{MOOS Variables Subscribed for by uSimCurrent}
\label{sec_usc_subs}

Variables subscribed for by \app{uSimCurrent} are summarized below.

\begin{packed_itemize}[2]
\item \mvar{NAV\_X}: The ownship vehicle position on the $x$ axis of
  local coordinates.

\item \mvar{NAV\_Y}: The ownship vehicle position on the $y$ axis of
  local coordinates. 
\end{packed_itemize}

\end{document}

</pre></body></html>