Wednesday, November 18, 2015

Mini Project 2 - Process





Enterface: Dreammachine v2.0 is a cover of Brion Gysin and William S. Burrough's DreamMachine. The interface device is designed to control light pulses in sync with alpha brain waves to create hallucinations. A thermoresistor controls the pulses from a range of 8pps to 13pps. The cooling face gel mask and neck pillow relaxes the 'viewer' as they enjoy the show. The slowing of breath often increases the temperature and keeps it steady.

Not exactly rocket science. Thankfully we're making art, not rockets. To all you having trouble this is how simple your circuit can be, but think more critically on how to apply it. Ya'll are having so many issues with this portion so maybe simplify the circuitry and home in on your interfaces.



My coding was simple and custom-built using IF/THEN statements and set variables that turn off the pulsing with ambient room temperature. I used Gysin's maths for my maths. The cylinder is essentially circuitized.

//TMP36 Pin Variables
const int POT=0;  //Pot on analog pin 0
int val = 0;   
const int LED=9;       //define LED for Pin 9
const int EIGHT=150;
const int NINE=154;
const int TEN=158;
const int ELEVEN=161;
const int TWELVE=164;
const int THIRTEEN=168;
void setup()
{
  Serial.begin(9600);  //Start the serial connection with the computer
                       //to view the result open the serial monitor 
  pinMode (LED, OUTPUT);
}

void loop()                     // run over and over again
{
    val = analogRead(POT);
  Serial.println(val);
 if (val > EIGHT)
 {
  digitalWrite(LED, HIGH);
  delay(63);
  digitalWrite(LED, LOW);
  delay(263);
 }
 else if (val > NINE)
 {
  digitalWrite(LED, HIGH);
  delay(56);
  digitalWrite(LED, LOW);
  delay(156);
 }
 else if (val > TEN)
 {
   digitalWrite(LED, HIGH);
  delay(50);
  digitalWrite(LED, LOW);
  delay(50);
 }
 else if (val > ELEVEN)
 {
   digitalWrite(LED, HIGH);
  delay(45);
  digitalWrite(LED, LOW);
  delay(45);
 }
 else if (val > TWELVE)
 {
   digitalWrite(LED, HIGH);
  delay(42);
  digitalWrite(LED, LOW);
  delay(42);
 }
 else if (val > THIRTEEN)
 {
   digitalWrite(LED, HIGH);
  delay(38);
  digitalWrite(LED, LOW);
  delay(38);
 }
 else if (val < EIGHT)
 {
  digitalWrite(LED, LOW);
 }
 delay(50);                                     //waiting a second
}

No comments:

Post a Comment