Natalie C. Landon-Brace edited PIC.tex  about 10 years ago

Commit id: 79fc95848b4d8f77912cda9986e987b123fce22b

deletions | additions      

       

\end{itemize}  \subsubsection{Detecting and Interpreting User Input}  Both in standby mode and upon completion of the operation, the machine requires user input in order to proceed. In standby mode, the machine simply requires the operator to push star (*) <*>  to start the checking operation. Upon completion of the program, the user is prompted to push for Operation Time, for a Summary (total number of lights tested, abbreviation for each light's status), for detailed light statistics (the status of an individual light) or to return to standby mode so the operation can begin again. During both of these times, the machine polls for input by displaying a message and continuing to check whether RB1 has been activated. Once RB1 has been activated, the key code RB7:4 is read in to the program. The keycode is then saved to a temporary register and exclusive or-ed with a preset code. The code for this can be seen in Figure \ref{fig:Button_Press}, which shows the checking routine for the star (*) <*>  button. If the codes match (the result is 0) the subroutine associated with that code will execute. Otherwise, the keycode is reloaded from the temporary register and the process is repeated until a match is found, or all possibilities are exhausted. In the second case, the machine will maintain the same display. \subsection{Program Details}  \subsection{Suggestions for Improvement}