Announcements

November 24, 2007
Reading for November 27th, are now posted. Enjoy!

October 2, 2007
To upload your thoughtless acts, create a new assignment page like any other lab. You'll see "Thoughtless Acts" listed as one of the assignment options.

May 24, 2008
This site has been archived and is no longer editable. Stay tuned for the next version, coming in the fall!


Prayer flag project

Project Members: 
Katherine Ahern

Description

Many Tibetan Buddhists hang prayer flags in the breeze, believing that the wind will carry prayers of peace and compassion all over the world. In my project, I attached a prayer flag to a DC Motor, and when you press the FSR the prayer flag spins, so you could use the FSR sort of like Catholics use a rosary, to send prayers out. It isn't really very meditative, though!

There was a little problem in that the diode only seemed to work for a little while (like there was too much power for it, or something), so after a bit the flag would just start spinning regardless of the FSR readings. That's why, in the picture, the flag is spinning even though no one is pressing the FSR.

Components

Battery pack
diode
FSR
Battery pack with 2 batteries
wires

Arduino Code

/*
* Katherine Ahern
* this is the same as potControlsMotor,
* but I attached an FSR instead of the pot
* modified version of AnalogInput
* by DojoDave
* http://www.arduino.cc/en/Tutorial/AnalogInput
* Modified again by dave
*/

int fsrPin = 0; // select the input pin for the potentiometer
int motorPin = 9; // select the pin for the Motor
int val = 0; // variable to store the value coming from the sensor
void setup() {
Serial.begin(9600);
}
void loop() {
val = analogRead(fsrPin); // read the value from the sensor, between 0 - 1024
Serial.println(val);
analogWrite(motorPin, val/4); // analogWrite can be between 0-255
}


Comments

Comments from TAs

Cool project, and nice idea. You say that the fast spinning isn't particularly meditative, so it would be good to think about ways to get an interaction that you're happier with. For example, you could set the "analogWrite()" command to send a smaller value to make the motor spin slower... e.g. make it always send the same value, regardless of how hard the FSR is pressed. If that didn't work, you could also reduce the voltage of your batteries or insert a resistor to slow down the spinning.

It would be interesting to consider other was of triggering the flags. For example, they could spin randomly, like an invisible wind. Or you could connect them to something like Jonathan's remote weather project to detect when there's wind on a real mountain and then make the flag move proportionately.


Powered by Drupal - Design by Artinet