Monday, October 5, 2009

Physical Computing: Week Four Lab

In week four, Physical Computing turned to using our analog output to work creating productive output products.  This included two labs, creating output in two forms.  The first was a servo lab, which took an analog input and mapped it to the physical movement of a servo.  The second was a tone lab, which took analog input and mapped it to the output of a small speaker.  Both demonstrated that an analog sensor can easily be used to create tangible output effects.


In the first lab, we wired a circuit to include an analog sensor and a servo.  In this photo we can see this circuiy implemented, with a flex sensor in place to control the servo.


Once the circuit was completed, a simple upload of the lab's arduino program yielded the behavior seen in the video above. Either a manual pulsing or the arduino servo library could be used, and the same behavior resulted. In short, the flex sensor's analog output controls the position of the servo.


The second lab followed a similar concept, but instead used the sensor to control tone on a speaker. I chose to use a potentiometer for my control, so that dialing it would control pitch. This circuit can be see above.


Once wired, this circuit also required a small arduino program that would map the analog inputs to an analog output value for the speaker. In the video above, the potentiometer is being moved, and the resulting speaker tone changes in turn.

No comments:

Post a Comment