Light/Time :: Breath
For this project I wanted to create a tool that I could using for a performance I am creating. The concept behind it, is that a dancer is able to control a light source with her breath. The fluctuations through the expanding and contracting of her chest vary the strength of the light. The piece then becomes a metaphor for life, drawing attention to the constant physical act of breathing, and how it keeps us alive.
It was made by using a stretch sensor that detected the amount of movement in the chest while breathing. This data was then sent to another arduino using an xbee. The receiving arduino was connected to a servo, that would adjust a dimmer switch according to the stretch data it was being sent.
The Reciever
Code:
#include
Servo myServo;
float timer;
byte incomingByte;
int servoPos [3];
void setup(){
Serial.begin(9600);
myServo.attach(11);
}
void loop(){
// see if there's incoming serial data:
if (Serial.available() > 0) {
// read the oldest byte in the serial buffer:
// servoPos[0] = Serial.read();
// servoPos[1] = Serial.read();
//servoPos[2] = Serial.read();
// for (int i = 0; i < 3; i = i + 1) {
incomingByte = Serial.read();
Serial.println(int(incomingByte));
myServo.write(int(incomingByte));
}
}
The Transmitter
Code:
int stretchAnalogPin = 0; // stretch is connected to analog 0
int stretchReading; // the analog reading from the stretch resistor divider
int expand = 56;
int contract = 41;
void setup()
{
Serial.begin(9600);
}
void loop()
{
stretchReading = analogRead(stretchAnalogPin);
//Serial.println(stretchReading);
byte servoPos = byte(map(stretchReading, contract, expand, 30, 150));
Serial.print(servoPos);
delay(100);
}

