user16455: I want to have a switch, that when on, will grab an analog number and essentially "freeze" it. Similarly to how STO> works on a TI83. What should I be using? Excuse my lack of technical terms, I'm not sure what to search and therefore do not know what to use. Thank you :)

user30002: My recommendation:

Configure an external interrupt on the raising edges of the input where the button/switch is wired. Note that only pins 2 and 3 of Uno are capable of external interrupts.
Write a very simple ISR that just sets to True a global volatile variable (a flag to signal that the button/switch has been actuated) and does nothing else.
In the loop() check if the flag variable has been changed by the interrupt. If that's the case, then:

Debounce/deglitch the button/switch (optional, but highly recommended).
Read the analog input of your choice and store its value or do whatever you want to do with it.
Reset the flag variable to False so it can be changed the next time the interrupt is fired. 



16455: <p>I want to have a switch, that when on, will grab an analog number and essentially "freeze" it. Similarly to how STO> works on a TI83. What should I be using? Excuse my lack of technical terms, I'm not sure what to search and therefore do not know what to use. Thank you :)</p>
 30002: <p>My recommendation:</p>

<ol>
<li><p>Configure an external interrupt on the raising edges of the input where the button/switch is wired. Note that only pins 2 and 3 of Uno are capable of external interrupts.</p></li>
<li><p>Write a very simple ISR that just sets to <code>True</code> a global <code>volatile</code> variable (a flag to signal that the button/switch has been actuated) and does nothing else.</p></li>
<li><p>In the <code>loop()</code> check if the flag variable has been changed by the interrupt. If that's the case, then:</p>

<ul>
<li>Debounce/deglitch the button/switch (optional, but highly recommended).</li>
<li>Read the analog input of your choice and store its value or do whatever you want to do with it.</li>
<li>Reset the flag variable to <code>False</code> so it can be changed the next time the interrupt is fired. </li>
</ul></li>
</ol>
