<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_memo_format}
%===================================================================

\begin{document}

\begin{labcover}
\labtitle{The Alpha End Flag Mission - Verifying Waypoint EndFlag Functionality}
\vspace{0.1in}
\labdate{January 2024}
\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=Memo.VVMissionAlpha}
\wikidoc{auth=mikerb@mit.edu}
\wikidoc{toc=false}

%===================================================================
\section{The Alpha End Flag Mission}

The \mis{Alpha End Flag} mission is a variation of the \mis{Alpha}
mission which is the "Hello World!" initial mission. This test mission
is designed to test a single feature of the Waypoint behavior. The
Waypoint behavior is designed to traverse a set of waypoints, some
number of times, and upon reaching the last waypoint, post {\em end
  flags}.  In this mission the end flag is configured simply as:

\prevbhv
\begin{verbatim}
  endflag = EFLAG=$[CTR]
\end{verbatim}
\postverb

\vspace{0.1in}
\noindent
Upon completion, the Waypoint behavior will post the MOOS variable
\mvar{EFLAG} with the value being the expanstion of the macro
\var{\$[CTR]} which is incremented each time it is posted, with the
first value being $1$. This is a pretty simple bit of functionality to
test, but the proper functioning of end flags is vitally important to
many autonomy missions, so we certainly want to include a test like
this in our automated tests. The mission when executed looks something
like that shown in Figure \ref{fig_v1_alpha}.


\vspace{0.1in}
\begin{figure}[H]
  \centering
  \includegraphics[width=0.85\textwidth]{figures/v1_alpha_final.png}
  \caption{{\bf The Alpha EndFlag Mission}: After a vehicle has
    traversed its complete set of waypoints, the waypoint behavior is
    configured to post and {\em endflag}. A configured flag consists of
    a MOOS variable (\var{EFLAG} here), and a variable value. In this
    case the variable value is configured to post the integer
    representing the number of times the endflag has been posted. This
    mission is designed to test solely this feature of the waypoint
    behavior.}
  \label{fig_v1_alpha}
  \urlvideo{http://vimeo.com/538154353}{0:22}
\end{figure}

\noindent
This mission is augmented with the \app{pMissionEval} app running
alongside the normal \mis{Alpha} mission apps. This app is configured
to check for the presence of the end flag, \mvar{EFLAG=1}, after
reaching the final point.

\vspace{0.1in}
\noindent
In the simplest configuration, the mission can be first launched
manually with the observer noting the rough number of seconds it takes
for the vehicle to traverse its points. The {\em lead} criteria can
simply be whether the proper amount of time has elapsed. The checking
step is handled by noting the value of \mvar{EFLAG} after the wait
time has been satisfied. Either \mvar{MISSION\_RESULT=true} or
\mvar{MISSION\_RESULT=false} will be posted by \app{pMissionEval}. The
configuration for \app{pMissionEval} contains the following
configuration.

\prevblue
\begin{verbatim}
  lead_condition = START_TIME_DELTA &gt; 50
  pass_condition = EFLAG = 1
  pass_flag      = MISSION_SUCCESS = true
  fail_flag      = MISSION_SUCCESS = false
\end{verbatim}
\postverb

\noindent
Again, the \app{pMissionEval} app will be fully covered in Section
\ref{sec_pme}, but the above pattern of (a) lead condition(s), (b)
check conditions, and (c) posting flags, will be a recurring pattern
for describing how a mission is tested.

\vspace{0.1in}
\noindent
The \mis{Alpha End Flag} test mission is automated by launching the
mission within a script, which then proceeds to repeatedly query the
MOOSDB while the mission is running for the presense of either
\mvar{RESULT=true} or \mvar{RESULT=false}. When one of these has been
detected in the running MOOSDB, the script halts all apps in the
mission. The script then scrapes the resulting log file for either
\mvar{RESULT=true} or \mvar{RESULT=false}, and the result included in
the automated tabulation of test missions.

%------------------------------------------------------------------
\subsection*{{\em Alpha End Flag} Mission Summary}

\begin{packed_itemize}
\item {\bf Evaluation Type}: This mission explicitly tests the
  \bvar{endflag} parameter and functionality in the Waypoint
  behavior. The evaluation type is {\em functional}.
\item {\bf Mission Structure}: This mission is comprised of a single
  vehicle running as a single MOOS community of apps, using a single
  MOOSDB. The mission structure is {\em singular}.
\item {\bf Machine Structure}: All apps in this mission are running on
  a single machine. Although the MOOS middleware supports distribution
  of singular missions across multiple machines, this is rare. The
  machine structure for this mission is {\em single machine}.
\item {\bf Evaluation Focus}: Since there is only one vehicle, the
  evaluation focus is on {\em ownship}.
\end{packed_itemize}

\end{document}



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