<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
   <channel>
      <title>Living Art</title>
      <link>http://itp.nyu.edu/~cb1591/livingart/</link>
      <description></description>
      <language>en</language>
      <copyright>Copyright 2007</copyright>
      <lastBuildDate>Wed, 04 Apr 2007 18:36:19 +0000</lastBuildDate>
      <generator>http://www.sixapart.com/movabletype/?v=3.2</generator>
      <docs>http://blogs.law.harvard.edu/tech/rss</docs> 

            <item>
         <title>Final - Garbage Can</title>
         <description><![CDATA[<p>For my final in Living Art, I'm attempting to make a garbage can that hate garbage.  The idea is that whenever anything gets thrown into the can, the lid to the garbage can will open and reject what ever object is put inside.  </p>

<p>My progress so far:</p>

<p>1) I bought a garbage can<br />
2) Located an IR sensor to detect objects</p>

<p><br />
</p>]]></description>
         <link>http://itp.nyu.edu/~cb1591/livingart/2007/04/final_garbage_can.html</link>
         <guid>http://itp.nyu.edu/~cb1591/livingart/2007/04/final_garbage_can.html</guid>
         <category></category>
         <pubDate>Wed, 04 Apr 2007 18:36:19 +0000</pubDate>
      </item>
            <item>
         <title>First Assignment - Finite State Machine</title>
         <description><![CDATA[<p>Sitting around a table in the Japanese Room I started talking with James Daher about Living Art and our first assignment a 'Finite State Machine'.  We discussed what it was and the terms we used to define what a Finite State Machine and realized it was anything.  This lead to a simple yet childish idea of blowing up balloons and having them pop over other people's heads.  Eventually we came up with this strange idea of building this contraption with foot pumps and air tubes that would blow up balloons over the people using the foot pumps.  </p>

<p><img alt="firstDrawing.jpg" src="http://itp.nyu.edu/~cb1591/livingart/images/firstDrawing.jpg" width="500" height="477" /></p>

<p>We then developed the idea using 4 people facing each other, but not knowing which balloon they were pumping up:<br />
<img alt="2ndDrawing.jpg" src="http://itp.nyu.edu/~cb1591/livingart/images/2ndDrawing.jpg" width="500" height="509" /></p>

<p>Lucky for me I was working with James who realized my design could be slimmed down or streamlined using a pole:<br />
<img alt="3rdDrawing.jpg" src="http://itp.nyu.edu/~cb1591/livingart/images/3rdDrawing.jpg" width="500" height="479" /></p>

<p>And here is our final drawing before we bought any of our materials:<br />
<img alt="4thDrawing.jpg" src="http://itp.nyu.edu/~cb1591/livingart/images/4thDrawing.jpg" width="500" height="492" /></p>

<p>The more we developed the design the more the game was developed, and one aspect we thought could be really interesting was if we could rotate the balloons as the users pumped them up.  This of course was going to be difficult considering all the tubes we need to use running from 4 separate foot pumps to 4 separate balloons in one piece of PVC piping.  And to be honest I didn't have much faith in getting that part to work.  We figured if we can build it and get it working then we will add a motor and try to rotate it.</p>

<p>We went to Home Depot and bought:<br />
10 Feet of PVC piping<br />
A bunch of PVC piping ends for the 4 different direction on the top<br />
50 feet of polyurethane tubing</p>

<p>We cut the PVC to about 7 feet ran four tubes up it and used an old bike pump James had to see if we could blow up a balloon.  It worked so we started building it!!  We were able to get the structure built in about an hour, which meant it's time to see if we can rotate this thing.  </p>

<p>The major issue was not getting the tubes tangled up as it rotates and people are using the foot pumps to blow up the balloons.  So the PVC Pipe could rotate in one direction and reverse it's direction and continue this back and forth motion so nothing got tangled.  <br />
Here is our motor:<br />
<img alt="motor.jpg" src="http://itp.nyu.edu/~cb1591/livingart/images/motor.jpg" width="500" height="478" /></p>

<p>And this is what we came up with:<br />
<img alt="bottomofPVC.jpg" src="http://itp.nyu.edu/~cb1591/livingart/images/bottomofPVC.jpg" width="500" height="743" /><br />
As you can see there is a motor attached to the bottom which we will have attached to a small ledge inside a box that needs to be build to stablize the entire structure.  The motor will remain stationary on the ledge as it rotates the round pieces of wood with the wooden spokes going through the PVC piping.  This way only the PVC rotates.  </p>

<p>Now we need a box to put this in, luck for us I built one for my P-Comp final last semester and had wood left over:<br />
<img alt="boxWhite.jpg" src="http://itp.nyu.edu/~cb1591/livingart/images/boxWhite.jpg" width="500" height="713" /></p>

<p>Here is our ledge inside the box for the motor to rest on:<br />
<img alt="shelf.jpg" src="http://itp.nyu.edu/~cb1591/livingart/images/shelf.jpg" width="500" height="429" /></p>

<p>Now inorder for the tubes not to get tangled we need to make sure the motor will not fully rotate but only rotate about 200 degrees then reverse it's direction.  So we need two switches that will be hit at the right time and tell the motor to reverse it's direction:<br />
<img alt="switch.jpg" src="http://itp.nyu.edu/~cb1591/livingart/images/switch.jpg" width="500" height="375" /></p>

<p>We ran into a few issues with our program, since neither James or I are programmers.  Luck for us we have some kind people in our class that were willing to help, like Rory.  Here is our final program that we used for our motor and 2 switches:</p>

<p>*********************************  BORING CODE STUFF  *******************************<br />
/*James and Christian's Balloon Tree<br />
  Code using one motor and 2 switches */<br />
int motorPin0 = 2;         //  PIN IN THE H-BRDIGE TO THE ARDUINO FOR THE MOTOR<br />
int motorPin1 = 3;         //  PIN IN THE H-BRDIGE TO THE ARDUINO FOR THE MOTOR</p>

<p>int switchPin1 = 7;        // PIN FOR SWITCH1 TO THE ARDUINO<br />
int switchPin2 = 8;        // PIN FOR SWITCH2 TO THE ARDUINO</p>

<p>int state1 = 0;             // THE INITIAL STATE OF THE SWITCH1, OPEN<br />
int state2 = 0;            // THE INITIAL STATE OF THE SWITCH2, OPEN<br />
int motorPinSwap = 0;      // VARIABLE USED TO CHANGE THE DIRECTION OF THE MOTOR<br />
int motorPin0value = HIGH; // VARIABLE USED FOR THE MOTOR'S DIRECTION<br />
int motorPin1value = LOW;  // VARIABLE USED FOR THE MOTOR'S DIRECTION</p>

<p>boolean previouslyPressed1 = false;  //BOOLEAN STATEMENT USED TO UNDERSTAND THE PREVIOUS STATE OF SWITCH1<br />
boolean previouslyPressed2 = false;  //BOOLEAN STATEMENT USED TO UNDERSTAND THE PREVIOUS STATE OF SWITCH2<br />
//**********************************************  SETUP  ****************************************************<br />
void setup() {<br />
Serial.begin(9600);<br />
pinMode(motorPin0, OUTPUT);<br />
pinMode(motorPin1, OUTPUT);<br />
//the switch is an input<br />
pinMode(switchPin1, INPUT);<br />
pinMode(switchPin2, INPUT);<br />
}<br />
//********************************************  LOOP *****************************************************<br />
void loop() {<br />
digitalWrite(motorPin0,motorPin0value);  //STARTS THE MOTOR IN ONE DIRECTION USING THE VARIABLE motorPin0value<br />
digitalWrite(motorPin1,motorPin1value);  //STARTS THE MOTOR IN ONE DIRECTION USING THE VARIABLE motorPin1value</p>

<p>//************************************  READING SWITCH1  **************************************   <br />
state1 = digitalRead(switchPin1);       //READING THE STATE SWITCH1<br />
Serial.print(motorPin0value,DEC);       //PRINT LINE<br />
Serial.println(motorPin1value,DEC);     //PRINT LINE<br />
//*********************************  IF STATEMENT FOR SWITCH1  ******************************<br />
if(state1 == 1 && previouslyPressed1 == false)  //IF STATEMENT IN ORDER TO CHANGE THE MOTORS DIRECTION<br />
{                                               //IF SWITCH1 IS TURNED ON, AND IT WAS NOT PREVIOUSLY PRESSED<br />
    motorPinSwap = motorPin0value;              //THEN SWITCH THE PIN AND REVERSE THE DIRECTION OF THE MOTOR<br />
    motorPin0value = motorPin1value;            //WHICH IN RETURN MEANS THE SWITCH AS BEEN PREVIOUSLY PRESSED<br />
    motorPin1value = motorPinSwap;              //WHICH IS WHY IT IS NOW "TRUE"<br />
    <br />
    previouslyPressed1 = true;<br />
}<br />
else if(state1 == 0)                            //ELSE IF THE SWITCH IS NOT TURNED ON THAN IT HAS ALSO NOT<br />
    previouslyPressed1 = false;                 //BEEN PREVIOUSLY PRESSED<br />
   <br />
//*************************************  READING SWITCH2  ***************************************<br />
state2 = digitalRead(switchPin2);       //READING A SECOND STATE USING SWITCH2<br />
Serial.print(motorPin0value,DEC);<br />
Serial.println(motorPin1value,DEC);<br />
//*******************************************  IF STATEMENT FOR SWITCH2  **************************************<br />
if(state2 == 1 && previouslyPressed2 == false)  //IF STATEMENT IN ORDER TO CHANGE THE MOTORS DIRECTION<br />
{<br />
    motorPinSwap = motorPin0value;           <br />
    motorPin0value = motorPin1value;<br />
    motorPin1value = motorPinSwap;<br />
    <br />
    previouslyPressed2 = true;<br />
}<br />
else if(state2 == 0)<br />
    previouslyPressed2 = false;<br />
}<br />
****************************  END OF BORING CODE STUFF  ********************************<br />
As this thing slowly came together we realized it was going to be rather ridiculous.  It had more and more of a carnival feel the more it was built.  So James and decide to run with it as you see here:<br />
<img alt="painting.jpg" src="http://itp.nyu.edu/~cb1591/livingart/images/painting.jpg" width="500" height="453" /></p>

<p>We had some problems with burning out pins in our Arduino along with burning out pins in the H-Bridge we used to controll our motor.  This caused major frustrations all the way up until midnight of the night before we presented.  We got the motor working properly around midnight without being hooked up with all the tubes and foot pumps.  But we didn't want to do anything to prevent the motor from working so we decide to hook it all up and then plug it in the next morning and hope for the best.  We left that night with it for the first time all put together:<br />
<img alt="finished.jpg" src="http://itp.nyu.edu/~cb1591/livingart/images/finished.jpg" width="500" height="708" /></p>

<p>Soooo, we explained how it worked and the fact it has never been completely hooked up before with a working motor.  So we have no idea what is about to happen.   And to our disbelief it worked exactly how we imagined it.  Living Art Dreams do come true!!</p>

<p><object width="425" height="350"><param name="movie" value="http://www.youtube.com/v/0GAQmwiHjuE"></param><param name="wmode" value="transparent"></param><embed src="http://www.youtube.com/v/0GAQmwiHjuE" type="application/x-shockwave-flash" wmode="transparent" width="425" height="350"></embed></object></p>]]></description>
         <link>http://itp.nyu.edu/~cb1591/livingart/2007/02/first_assignment_finite_state_1.html</link>
         <guid>http://itp.nyu.edu/~cb1591/livingart/2007/02/first_assignment_finite_state_1.html</guid>
         <category></category>
         <pubDate>Fri, 02 Feb 2007 06:14:26 +0000</pubDate>
      </item>
      
   </channel>
</rss>
