Changes

Week 3 Lab

52 bytes removed, 06:16, 13 April 2009
Potentiometer
=== Potentiometer ===
[[Image:Pot_in.png]]
* <code>A_IN</code> can be any of the <code>Analog</code> pins (0-5) on your Freeduino. * Q: What will the voltage at <code>A_IN</code> be? What are the upper and lower values?
* The important part of this sketch is the line where the microprocessor reads the analog input:
<code>
val = analogRead(potPin); // read the value from the sensor
</code>
* Q: Looking at the Arduino help for that function (<code>analogRead()</code>), what do you think the value <code>val</code> will be for those highest and lowest voltages at your <code>A_IN</code> pin?
* Q: How can you verify your guess? Try and verify your values, in some way. Anything goes!!!