<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Pixel Punchout &#187; Intro to Computational Media</title>
	<atom:link href="http://pixelpunchout.com/tag/intro-to-computational-media/feed/" rel="self" type="application/rss+xml" />
	<link>http://pixelpunchout.com</link>
	<description>digital/social media, technology, internet phenomena, + design (ninjas)</description>
	<lastBuildDate>Tue, 31 Aug 2010 05:38:57 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Meet TweetChime</title>
		<link>http://pixelpunchout.com/2009/12/meet-tweetchime/</link>
		<comments>http://pixelpunchout.com/2009/12/meet-tweetchime/#comments</comments>
		<pubDate>Fri, 04 Dec 2009 06:05:33 +0000</pubDate>
		<dc:creator>Cindy</dc:creator>
				<category><![CDATA[ITP]]></category>
		<category><![CDATA[Add new tag]]></category>
		<category><![CDATA[Intro to Computational Media]]></category>
		<category><![CDATA[Physical Computing]]></category>
		<category><![CDATA[TweetChime]]></category>

		<guid isPermaLink="false">http://www.pixelpunchout.com/?p=560</guid>
		<description><![CDATA[TweetChime Live Demo from cindy wong on Vimeo. Helping people overcome long distances, TweetChime is a melodic chime that communicates people&#8217;s sentiments and transmits them into melody. So, no matter where you are, you can let your loved ones know you&#8217;re thinking of them and they can hear your sentiment in real-time in sound. By [...]]]></description>
			<content:encoded><![CDATA[<p><object width="500" height="375" data="http://vimeo.com/moogaloop.swf?clip_id=8017119&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=00ADEF&amp;fullscreen=1" type="application/x-shockwave-flash"><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://vimeo.com/moogaloop.swf?clip_id=8017119&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=00ADEF&amp;fullscreen=1" /></object></p>
<p><a href="http://vimeo.com/8017119">TweetChime Live Demo</a> from <a href="http://vimeo.com/user758179">cindy wong</a> on <a href="http://vimeo.com">Vimeo</a>.</p>
<p>Helping people overcome long distances, <a href="http://itp.nyu.edu/~cw1028/pcomp/tweetchime.html" target="_blank">TweetChime</a> is a melodic chime that communicates people&#8217;s sentiments and transmits them into melody. So, no matter where you are, you can let your loved ones know you&#8217;re thinking of them and they can hear your sentiment in real-time in sound. By using Twitter, you can send your preferred sentiment, anytime and anywhere at your convenience.</p>
<p>In this case, in the video above, my brother, Pat has sent me this coded message: &#8220;<a onclick="pageTracker._trackPageview('/exit/to/tweetchime')" href="http://twitter.com/tweetchime" target="_blank"><strong>@tweetchime</strong></a> [dinnertime] awww yeah!&#8221; Why? Because he has an odd sense of humor  from living in Mobile, Al. which somehow is lost on me  in New York City. Ah, family.</p>
<h2>Who Could Use TweetChime?</h2>
<p>TweetChime is great for ambient contact technology. In other words, you can keep yourself open to others without them having to actively message you (through phone/IM/email). Vice versa, they can quickly tweet you and have the satisfaction of knowing that you will hear their tweet melody in real time on your side.  The TweetChime is unobtrusive and (if prototyped further) can blend into your household.</p>
<ul>
<li>Long distance friends/family</li>
<li>Parents who want to communicate with their kids (who can&#8217;t read time, distinguish technology)</li>
<li>Visually Impaired</li>
</ul>
<h2>Interact with TweetChime:</h2>
<p>Would you like to send a sentiment to me? Please tweet to <strong>@tweetchime</strong>, the TweetChime&#8217;s Twitter account.</p>
<p><strong>How to Send: </strong>TweetChime recognizes the coded message within the brackets [ ]. The TweetChime website will scan Twitter&#8217;s search results looking for messages aimed at @tweetchime.</p>
<p>I have programmed a reply that TweetChime can recognize from a Twitter message. Choose your choice below:</p>
<ul>
<li>@tweetchime [be happy]</li>
<li>@tweetchime [congratulations]</li>
<li>@tweetchime [missing you]</li>
<li>@tweetchime [holla]</li>
<li>@tweetchime [coming home]</li>
<li>@tweetchime [dinner time]</li>
</ul>
<p><em>ex: cwong08 says: &#8220;@tweetchime [dinner time] Mom is serving mashed potatoes and turkey! Mmmm!</em></p>
<p><strong>Where Does My Tweet Go?</strong><a href="http://itp.nyu.edu/~cw1028/pcomp/tweetchime_beta.html" target="_blank"></a></p>
<p><a href="http://itp.nyu.edu/~cw1028/pcomp/tweetchime_beta.html" target="_blank">TweetChime</a> will be searching for all mentions of itself (@tweetchime) through Twitter&#8217;s public search time line. When it finds the coded tweet (1 of the 6 above), it&#8217;ll understand it and output into a short melody that the TweetChime owner will understand.</p>
<p><strong>See It In Action</strong></p>
<h2><span id="more-560"></span></h2>
<h2><strong>Software Setup:</strong></h2>
<p><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/12/picture-1.png"></a><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/12/screengrab_tweetchimewebsite.png" title="screengrab_tweetchimewebsite" rel="lightbox[560]"><img class="alignnone size-full wp-image-592" title="screengrab_tweetchimewebsite" src="http://www.pixelpunchout.com/wp-content/uploads/2009/12/screengrab_tweetchimewebsite.png" alt="screengrab_tweetchimewebsite" width="500" height="392" /></a></p>
<p><em>TweetChime &#8211; home page for the TweetChime machine</em></p>
<p>So, what&#8217;s running the online component of TweetChime? TweetChime involves 2 websites: TweetChime, the <a href="http://itp.nyu.edu/~cw1028/pcomp/tweetchime.html" target="_blank">html site </a>and a <a href="http://itp.nyu.edu/~cw1028/pcomp/tweetchime_rss.php" target="_blank">php site</a>. The recipient of all these TweetChime melodies has the TweetChime website open in their web browser. The TweetChime website is constantly communicating to its PHP site (via AJAX) which is  checking a RSS feed of Twitter&#8217;s search results for mentions of @tweetchime [coded message here]. The ones that are properly formatted get grabbed to TweetChime&#8217;s html website. That website has Javascript coding which allows serial communication between the PC and the Arduino. The website passes the encoded values (for example, [be happy] = byte value 65)  within the Twitter messages to the Arduino which can understand them and output the commands associated with each coded byte value. The beauty is that TweetChime will only play fresh tweets so that folks will always know that the tweet melody heard is something that was sent by someone in real time.</p>
<p><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/12/picture-31.png"></a><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/12/phpcode.jpg" title="phpcode" rel="lightbox[560]"><img class="alignnone size-large wp-image-593" title="phpcode" src="http://www.pixelpunchout.com/wp-content/uploads/2009/12/phpcode-1024x575.jpg" alt="phpcode" width="500" height="284" /></a></p>
<p><em>PHP site that is parsing the tweets that people are sending to @tweetchime</em></p>
<p><em><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/12/serialcommunication_javascript.gif" title="serialcommunication_javascript" rel="lightbox[560]"><img class="alignnone size-large wp-image-594" title="serialcommunication_javascript" src="http://www.pixelpunchout.com/wp-content/uploads/2009/12/serialcommunication_javascript-1024x421.gif" alt="serialcommunication_javascript" width="500" height="205" /></a></em></p>
<p><em>Javascript receives the parsed tweets and transmits to Arduino to output to TweetChime</em></p>
<ul>
<li><strong>Update: </strong>Managed to parse Twitter RSS data to now include the current Twitter sender, Twitter sender&#8217;s icon<em><br />
</em></li>
</ul>
<h2>Physical Setup</h2>
<p>Ingredients: 5 Servo Motors, 1 Arduino, 1 BreadBoard, 22-gauge wires, 5 large metal wind chimes, 5 tiny metal chime pipes (to act as knockers), plywood, DC jack, 12V DC adapter, voltage regulator, heat shield (to protect the voltage regulator from overheating)</p>
<p><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/12/sany0006.jpg" title="TweetChime Machine Setup" rel="lightbox[560]"><img class="alignnone size-large wp-image-564" title="TweetChime Machine Setup" src="http://www.pixelpunchout.com/wp-content/uploads/2009/12/sany0006-1024x775.jpg" alt="TweetChime Machine Setup" width="500" height="375" /></a></p>
<p>Servo Motors are mounted to a back board. Attached to each servo motor is a smaller wind chime pipe that acts as a knocker to produce a clear ring against the hanging wind chime tube pipe.<em> </em>The Arduino and breadboard are mounted behind the back board.</p>
<p><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/12/backoftweetchime.jpg" title="backoftweetchime" rel="lightbox[560]"><img class="alignnone size-full wp-image-565" title="backoftweetchime" src="http://www.pixelpunchout.com/wp-content/uploads/2009/12/backoftweetchime.jpg" alt="backoftweetchime" width="500" height="400" /></a></p>
<p><strong>Arduino Coding:</strong><br />
Did you know that the servo library can now handle multiple servos without it overloading the timing involved in it? I originally wrote my Arduino code to include delays with the Servo Library and for whatever reason, when I added my 4th servo motor, it got jittery, ran abruptly and sometimes went on randomly. It may or may not have been a power issue involving a misplaced wire. However, after talking to my professor Tom Igoe, he managed to demonstrate a way for me to orderly arrange my servo motors (with arrays rather then explicitly listing each servo motors and it&#8217;s individual slot pin). I also learned that when you use the Servo Library, you don&#8217;t have to deal with mounting servo motors on only PWM slots on the Arduino – you can use ANY slot (which in my case was ANY digital slot). Here&#8217;s the code I ended up with:</p>
<pre class="postCode">#include
// an array of instances of the Servo library:
Servo myServos[5];
int incomingByte = 0;  //SETS UP AS ZERO INTERACTION @ START.
int pos = 0;   

void setup() {
 Serial.begin(9600);
 // opens serial port, sets data rate to 9600 bps

 // initialize the servos in the array on pins 2,3,4,5,6
 // servo 0 = pin 2; servo 1 = pin 3, servo 2 = pin 4, servo 3 = pin 5, servo 4 = pin 6
 for (int thisServo = 0; thisServo &lt; 5; thisServo++) {
  int thisPin = thisServo + 2;
  myServos[thisServo].attach(thisPin);
 }

}

void loop() {
  if (Serial.available() &gt; 0) {
   // read the incoming byte:
   incomingByte = Serial.read(); // CHECKS FOR INCOMING SERIAL DATA.

   if(incomingByte == 70) {      // IF INCOMING DATA = 70, REACT.
       // MELODY 68 =  Chime Sequence = 0,5,0,5 = coming home

            for (int thisServo = 0; thisServo &lt; 1; thisServo++) {

            myServos[2].write(180); //  servo in array; swing forward in 180 deg.
            delay(500);

            myServos[2].write(100); //  servo in array; swing back 100 deg.
            delay(500);

            myServos[3].write(180);
            delay(500);

            myServos[3].write(100);
            delay(500);

            myServos[1].write(180);
            delay(500);
            // move to 0 degrees:
            myServos[1].write(100);
            delay(500);

           myServos[2].write(180);
            delay(500);

            myServos[2].write(100);
            delay(500);

            myServos[3].write(180);
            delay(500);

            myServos[3].write(100);
            delay(500);

            myServos[1].write(180);
            delay(500);
            // move to 0 degrees:
            myServos[1].write(100);
            delay(500);
            }
       } 

    if(incomingByte == 69) {      // IF INCOMING DATA = 69, REACT.
       // MELODY 68 =  Chime Sequence = 0,5,0,5 = dinner time

            for (int thisServo = 0; thisServo &lt; 1; thisServo++) {
            // move to 0 degrees:
            myServos[0].write(180); // first servo in array; swing forward
            delay(500);
            // move to 0 degrees:
            myServos[0].write(100);
            delay(500);

            myServos[4].write(180); // 2nd servo in array; swing back
            delay(500);
            // move to 0 degrees:
            myServos[4].write(100);
            delay(500);

            myServos[0].write(180); // 3rd servo in array; swing forward
            delay(900);
            // move to 0 degrees:
            myServos[0].write(100); // 3rd servo in array; swing back
            delay(900);

            myServos[4].write(180); // first servo in array; swing forward
            delay(900);
            // move to 0 degrees:
            myServos[4].write(100);
            delay(900);

            }
       } 

     if(incomingByte == 68) {      // IF INCOMING DATA = 67, REACT.
       // MELODY 68 =  Chime Sequence = 2,1,0,4,3 = HOLLA

            for (int thisServo = 0; thisServo &lt; 1; thisServo++) {
            // move to 0 degrees:
            myServos[2].write(180); // first servo in array; swing forward
            delay(500);
            // move to 0 degrees:
            myServos[2].write(100);
            delay(500);

            myServos[3].write(180); // 2nd servo in array; swing back
            delay(500);
            // move to 0 degrees:
            myServos[3].write(100);
            delay(500);

            myServos[1].write(180); // 3rd servo in array; swing forward
            delay(500);
            // move to 0 degrees:
            myServos[1].write(100); // 3rd servo in array; swing back
            delay(500);

          myServos[2].write(180); // first servo in array; swing forward
            delay(500);
            // move to 0 degrees:
            myServos[2].write(100);
            delay(500);

            myServos[3].write(180); // 2nd servo in array; swing back
            delay(500);
            // move to 0 degrees:
            myServos[3].write(100);
            delay(500);

            myServos[1].write(180); // 3rd servo in array; swing forward
            delay(500);
            // move to 0 degrees:
            myServos[1].write(100); // 3rd servo in array; swing back
            delay(500);
            }
       } 

       if(incomingByte == 67) {      // IF INCOMING DATA = 67, REACT.
         // MELODY 67 =  Chime Sequence = 1,3,1,2,0 = MISSING YOU

            for (int thisServo = 0; thisServo &lt; 1; thisServo++) {
            // move to 0 degrees:
            myServos[1].write(180); // first servo in array; swing forward
            delay(500);
            // move to 0 degrees:
            myServos[1].write(100);
            delay(500);

            myServos[3].write(180); // 2nd servo in array; swing back
            delay(500);
            // move to 0 degrees:
            myServos[3].write(100);
            delay(500);

            myServos[1].write(180); // 3rd servo in array; swing forward
            delay(500);
            // move to 0 degrees:
            myServos[1].write(100); // 3rd servo in array; swing back
            delay(500);

            myServos[2].write(180); // 4th servo in array; swing forward
            delay(500);
            // move to 0 degrees:
            myServos[2].write(100); // 4th servo in array; swing back
            delay(500);

            myServos[0].write(180); // 5th servo in array; swing forward
            delay(500);
            // move to 0 degrees:
            myServos[0].write(100); // 5th servo in array; swing back
            delay(500);
            }
       }
             if(incomingByte == 66) {      // IF INCOMING DATA = 65, REACT.
       // MELODY 66 =  Chime Sequence 0, 2, 4, 1, 3 = CONGRATULATIONS

            for (int thisServo = 0; thisServo &lt; 1; thisServo++) {
            // move to 0 degrees:
            myServos[0].write(180); // first servo in array; swing forward
            delay(500);
            // move to 0 degrees:
            myServos[0].write(100);
            delay(500);

            myServos[1].write(180); // 2nd servo in array; swing back
            delay(500);
            // move to 0 degrees:
            myServos[1].write(100);
            delay(500);

            myServos[2].write(180); // 3rd servo in array; swing forward
            delay(500);
            // move to 0 degrees:
            myServos[2].write(100); // 3rd servo in array; swing back
            delay(500);

            myServos[3].write(180); // 4th servo in array; swing forward
            delay(500);
            // move to 0 degrees:
            myServos[3].write(100); // 4th servo in array; swing back
            delay(500);

            myServos[4].write(180); // 5th servo in array; swing forward
            delay(500);
            // move to 0 degrees:
            myServos[4].write(100); // 5th servo in array; swing back
            delay(500);
            }
      }

    if(incomingByte == 65) {      // IF INCOMING DATA = 65, REACT.
       // MELODY 65 =  Chime Sequence 4,3,2,1,0

            for (int thisServo = 0; thisServo &lt; 1; thisServo++) {
            // move to 0 degrees:
            myServos[4].write(180); // first servo in array; swing forward
            delay(500);
            // move to 0 degrees:
            myServos[4].write(100);
            delay(500);

            myServos[3].write(180); // 2nd servo in array; swing back
            delay(500);
            // move to 0 degrees:
            myServos[3].write(100);
            delay(500);

            myServos[2].write(180); // 3rd servo in array; swing forward
            delay(500);
            // move to 0 degrees:
            myServos[2].write(100); // 3rd servo in array; swing back
            delay(500);

            myServos[1].write(180); // 4th servo in array; swing forward
            delay(500);
            // move to 0 degrees:
            myServos[1].write(100); // 4th servo in array; swing back
            delay(500);

            myServos[0].write(180); // 5th servo in array; swing forward
            delay(500);
            // move to 0 degrees:
            myServos[0].write(100); // 5th servo in array; swing back
            delay(500);
            }
       }
    }
  }</pre>
]]></content:encoded>
			<wfw:commentRss>http://pixelpunchout.com/2009/12/meet-tweetchime/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Final Proposal: FireChat Greeting Card</title>
		<link>http://pixelpunchout.com/2009/11/final-proposal-firechat-greeting-card/</link>
		<comments>http://pixelpunchout.com/2009/11/final-proposal-firechat-greeting-card/#comments</comments>
		<pubDate>Sun, 15 Nov 2009 02:47:37 +0000</pubDate>
		<dc:creator>Cindy</dc:creator>
				<category><![CDATA[ITP]]></category>
		<category><![CDATA[Intro to Computational Media]]></category>

		<guid isPermaLink="false">http://www.pixelpunchout.com/?p=498</guid>
		<description><![CDATA[For my  web development final, I knew I wanted to pursue my interests in social media, interactive design, and multimedia.  I&#8217;m pretty interested in technology that helps bring people together over the web to communicate/interact. So, how can I make it fun? FireChat is an interactive video website that serves as a hub for friends [...]]]></description>
			<content:encoded><![CDATA[<p><iframe src="http://docs.google.com/present/embed?id=df35f6dh_122fhwd6hdx&#038;size=m" frameborder="0" width="555" height="451"></iframe></p>
<p>For my  web development final, I knew I wanted to pursue my interests in social media, interactive design, and multimedia.  I&#8217;m pretty interested in technology that helps bring people together over the web to communicate/interact. So, how can I make it fun?</p>
<p><strong>FireChat</strong> is an interactive video website that serves as a hub for friends to deliver greeting card messages. Rather then have friends sign a paper card, why not have an electronic card where your friends can all personally deliver a video message to your intended recipient on 1 screen? Go to the website. Sign in. Create an e-card page. Upload your video message. Invite your friends and family to your e-card webpage so that they can upload their video messages too! When you&#8217;re ready, you can email your video-card recipient and they will get to see everyone&#8217;s well-wishes on 1 page in video! You know how some people hate having to sign cards? Sometimes, it&#8217;s easier to just say what you want outloud. Don&#8217;t worry, unlike handwritten notes, you can just re-record your message till you get it right.</p>
<p>Examples:<br />
<a href="http://www.pixelpunchout.com/wp-content/uploads/2009/11/picture-4.png" title="eVite" rel="lightbox[498]"><img class="alignnone size-medium wp-image-517" title="eVite" src="http://www.pixelpunchout.com/wp-content/uploads/2009/11/picture-4-300x203.png" alt="eVite" width="300" height="203" /></a><br />
<a href="http://www.pixelpunchout.com/wp-content/uploads/2009/11/picture-10.png" title="picture-10" rel="lightbox[498]"><img class="alignnone size-medium wp-image-527" title="picture-10" src="http://www.pixelpunchout.com/wp-content/uploads/2009/11/picture-10-300x183.png" alt="picture-10" width="300" height="183" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://pixelpunchout.com/2009/11/final-proposal-firechat-greeting-card/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Meet TweetChime, ITP Final Project</title>
		<link>http://pixelpunchout.com/2009/11/final-project-for-physical-computing/</link>
		<comments>http://pixelpunchout.com/2009/11/final-project-for-physical-computing/#comments</comments>
		<pubDate>Wed, 11 Nov 2009 05:40:33 +0000</pubDate>
		<dc:creator>Cindy</dc:creator>
				<category><![CDATA[ITP]]></category>
		<category><![CDATA[Intro to Computational Media]]></category>
		<category><![CDATA[Physical Computing]]></category>
		<category><![CDATA[TweetChime]]></category>

		<guid isPermaLink="false">http://www.pixelpunchout.com/?p=486</guid>
		<description><![CDATA[For my Final Project, I decided to combine my ICMW and PComp classes together and produce a single idea: Meet TweetChime. TweetChime is an interactive music chime that  that will take specially coded Twitter messages people send to you and transforms them into melody where you are. What makes that so special? Whether a friend [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/11/pcompgraphic1.jpg" title="pcompgraphic1" rel="lightbox[486]"><img class="alignnone size-large wp-image-543" title="pcompgraphic1" src="http://www.pixelpunchout.com/wp-content/uploads/2009/11/pcompgraphic1-1024x568.jpg" alt="pcompgraphic1" width="563" height="301" /></a></p>
<p>For my Final Project, I decided to combine my ICMW and PComp classes together and produce a single idea: Meet <a href="http://itp.nyu.eud/~cw1028/pcomp/tweetchime.html" target="_blank">TweetChime</a>. TweetChime is an interactive music chime that  that will take specially coded Twitter messages people send to you and transforms them into melody where you are. What makes that so special?</p>
<p>Whether a friend wants to express &#8220;Good Luck!&#8221;, &#8220;Congratulations!&#8221;, &#8220;Have a Great Day&#8221; or &#8220;Thinking Of You&#8221;, TweetChime transforms their greeting in a harmonious patterned musical chime melody in real time. Be pleasantly surprised when you hear the ringing of notes and know that someone – out there– is thinking of you. As an owner, you can decipher what people are messaging you based on the musical melody overheard.</p>
<p><strong>Interaction: </strong>Person tweets a message through a special code setup. Example: <em>@cwong08 says, &#8220;@tweetchime 65 #tweetchime.</em><br />
Among the selected messages are examples like &#8220;Have a Good Day!&#8221; &#8220;Miss You,&#8221; &#8220;Good Luck!&#8221;, &#8220;I Love You,&#8221; that are given specific number codes etc. Currently, numbers 65-68 are coded. The owner of the TweetChime machine will log on to the <a href="http://itp.nyu.eud/~cw1028/pcomp/tweetchime.html" target="_blank">TweetChime</a> website and activate their device. From there, the TweetChime website scans an RSS feed for impending tweets  for @tweetchime and refreshes your website with appropriate melody when triggered by friends and family&#8217;s tweets.</p>
<p><strong>Under the Hood:</strong> TweetChime is powered by Javascript, PHP, and an Arduino. The <a href="http://itp.nyu.eud/~cw1028/pcomp/tweetchime.html" target="_blank">TweetChime</a> website is built with Javascript to interact serially with the Arduino (via USB port). <a href="http://itp.nyu.eud/~cw1028/pcomp/tweetchime.html" target="_blank">TweetChime </a> website uses AJAX to scoop data from a PHP script that reads a Twitter RSS feed and parses numerical codes from people&#8217;s submitted tweets.  From there, it passes those byte values to the Arduino which then outputs it into the message&#8217;s cued  melody.</p>
<p><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/11/pcompmotorlayout1.jpg" title="pcompmotorlayout1" rel="lightbox[486]"><img class="alignnone size-full wp-image-533" title="pcompmotorlayout1" src="http://www.pixelpunchout.com/wp-content/uploads/2009/11/pcompmotorlayout1.jpg" alt="pcompmotorlayout1" width="500" height="500" /></a></p>
<p><strong>Setup</strong>: Arduino, PHP, Javascript, 5 wind chime tubes, servo motors, 5 mini metal tubes (strikers)</p>
<p>Each wind chime is paired with a servo motor that is wired to the Arduino.  When the Arduino checks for digital read messages, it will receive the values and trigger the servo motor to tap the chime in series. A message like &#8220;Have a Good Day!&#8221; would sound differently then a message like &#8220;Miss You.&#8221;</p>
<p>Here&#8217;s a video of me testing the sensor motors against the wind chimes I purchased to see if they&#8217;d resonate.<br />
<object width="500" height="375" data="http://vimeo.com/moogaloop.swf?clip_id=7676984&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=00ADEF&amp;fullscreen=1" type="application/x-shockwave-flash"><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://vimeo.com/moogaloop.swf?clip_id=7676984&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=00ADEF&amp;fullscreen=1" /></object></p>
<p><a href="http://vimeo.com/7676984">Testing Servo Motor for Final Project Use</a> from <a href="http://vimeo.com/user758179">cindy wong</a> on <a href="http://vimeo.com">Vimeo</a>.</p>
<p><object width="500" height="281" data="http://vimeo.com/moogaloop.swf?clip_id=7780825&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=00ADEF&amp;fullscreen=1" type="application/x-shockwave-flash"><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://vimeo.com/moogaloop.swf?clip_id=7780825&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=00ADEF&amp;fullscreen=1" /></object></p>
<p><a href="http://vimeo.com/7780825">Testing Prototype: TweetChime Web/ServoMotor Interaction</a> from <a href="http://vimeo.com/user758179">cindy wong</a> on <a href="http://vimeo.com">Vimeo</a>.</p>
<p><object width="500" height="281" data="http://vimeo.com/moogaloop.swf?clip_id=7790314&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=00ADEF&amp;fullscreen=1" type="application/x-shockwave-flash"><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://vimeo.com/moogaloop.swf?clip_id=7790314&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=00ADEF&amp;fullscreen=1" /></object></p>
<p><a href="http://vimeo.com/7790314">Physical Construction of TweetChime</a> from <a href="http://vimeo.com/user758179">cindy wong</a> on <a href="http://vimeo.com">Vimeo</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://pixelpunchout.com/2009/11/final-project-for-physical-computing/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ICM Midterm: Fashion Forecast</title>
		<link>http://pixelpunchout.com/2009/10/icm-midterm-fashion-forecast/</link>
		<comments>http://pixelpunchout.com/2009/10/icm-midterm-fashion-forecast/#comments</comments>
		<pubDate>Tue, 27 Oct 2009 01:41:03 +0000</pubDate>
		<dc:creator>Cindy</dc:creator>
				<category><![CDATA[ITP]]></category>
		<category><![CDATA[Intro to Computational Media]]></category>

		<guid isPermaLink="false">http://www.pixelpunchout.com/?p=417</guid>
		<description><![CDATA[So, for my midterm, I decided to expand on my original PHP application, WearCaster. It was originally a little PHP app that pulled up New York City temperature readings (from Yahoo! Weather RSS feed). Based on my temperature parameters, WearCaster would let me know what I needed to wear before I step out the door. Here&#8217;s [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/10/picture-4.png"></a><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/10/picture-4.png" title="picture-4" rel="lightbox[417]"><img class="alignnone size-full wp-image-421" title="picture-4" src="http://www.pixelpunchout.com/wp-content/uploads/2009/10/picture-4.png" alt="picture-4" width="501" height="381" /></a></p>
<p>So, for my midterm, I decided to expand on my original PHP application, <a href="http://itp.nyu.edu/~cw1028/icmw/week5/week5labzip2.php" target="_blank">WearCaster</a>. It was originally a little PHP app that pulled up New York City temperature readings (from Yahoo! Weather RSS feed). Based on my temperature parameters, WearCaster would let me know what I needed to wear before I step out the door. Here&#8217;s my original <a href="http://www.pixelpunchout.com/2009/10/11/338/" target="_blank">blog post </a>documenting it. For the midterm, to avoid potential conflict with another company/individual, I changed the name (apparently, wearcaster.com, has been bought/squatted).</p>
<p>Please follow this link to see my presentation of <a href="http://itp.nyu.edu/~cw1028/icmw/midterm/fashionforecast.php" target="_blank">Fashion Forecast</a> for Intro to Computational Media for the Web.</p>
<p><a href="http://docs.google.com/present/view?id=df35f6dh_111dq37wjhh" target="_blank">http://docs.google.com/present/view?id=df35f6dh_111dq37wjhh</a></p>
<p>This time&#8230;.</p>
<ol>
<li>Plug your Zip Code anywhere in the US</li>
<li>Choose a Wardrobe based on your personal fashion preference</li>
<li>It&#8217;s Guy + Girl friendly so nobody get&#8217;s left out!</li>
<li>More choices: Keep hitting that refresh button to see new outfits!</li>
</ol>
<p>So, during my brainstorming for Fashion Forecast, here were features I wanted to implement. However, due to the 1-week Midterm deadline turnaround, I wasn&#8217;t able to get them all here. However, it&#8217;s something to think about for future implementation.</p>
<p>1.  Wardrobe Selection based on fashion brand [Was able to implement]</p>
<p>2. Ability for user to customize Fashion Forecast with their own closet selections (via uploaded photo content). [PHP/Database creation, user accounts required. Haven't explored/learned that yet]</p>
<p>3. More weather variables (precipitation). [Found weather RSS feeds to be more complicated to parse, still haven't found a good service quite yet]</p>
<p><strong><em><span id="more-417"></span>Troubleshooting:</em></strong></p>
<p>1. <strong>Setting Temperature</strong>:  Rather then write a series of LONG IF STATEMENTS, (ex: if $myTemp &lt; 40 &amp;&amp; $myTemp &lt;= 55, etc.), for my temperature ranges, I created a function and variable that would fold that neatly to my two important functions (myAdvice function and the wardrobeImage function).</p>
<p><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/10/getmytemp.png" title="getmytemp" rel="lightbox[417]"><img class="alignnone size-thumbnail wp-image-432" title="getmytemp" src="http://www.pixelpunchout.com/wp-content/uploads/2009/10/getmytemp-150x150.png" alt="getmytemp" width="150" height="150" /></a></p>
<p>2.<strong> Randomizing Images (all 331 of them)</strong>: How to generate random images directly from PHP to my web browser? After consulting with fellow peers, I made 2 variables. $folderName to generate the path to the proper image folder based on the temperature parameter, $imageName to generate the randomized images per clothing item (top, bottoms, accessory, etc). Together, $folderName and $imageName would write the direct file path to the images needed per category.</p>
<p><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/10/php_wardrobe.png" title="php_wardrobe" rel="lightbox[417]"><img class="alignnone size-medium wp-image-431" title="php_wardrobe" src="http://www.pixelpunchout.com/wp-content/uploads/2009/10/php_wardrobe-300x269.png" alt="php_wardrobe" width="300" height="269" /></a></p>
<p><strong>3. Outputting Advice</strong>: One of my issues with PHP was handling arrays. After much consultation, I managed to make my messy code alot neater by packaging it below in a series of arrays.</p>
<p><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/10/myadvice.png" title="myadvice" rel="lightbox[417]"><img class="alignnone size-medium wp-image-429" title="myadvice" src="http://www.pixelpunchout.com/wp-content/uploads/2009/10/myadvice-300x88.png" alt="myadvice" width="300" height="88" /></a></p>
<p>PS: I would also  like to thank my ITP peers for helping me out when I was in some tough spots. Corey Menscher, Rune Madsen! Beers/Donuts/Cliff Bars all around.</p>
<p>Alright, enough reading, please check out my latest improvements to <a href="http://itp.nyu.edu/~cw1028/icmw/midterm/fashionforecast.php" target="_blank">Fashion Forecast</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://pixelpunchout.com/2009/10/icm-midterm-fashion-forecast/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>ICM-Web Midterm Proposal</title>
		<link>http://pixelpunchout.com/2009/10/icm-web-midterm-proposal/</link>
		<comments>http://pixelpunchout.com/2009/10/icm-web-midterm-proposal/#comments</comments>
		<pubDate>Mon, 19 Oct 2009 21:34:46 +0000</pubDate>
		<dc:creator>Cindy</dc:creator>
				<category><![CDATA[ITP]]></category>
		<category><![CDATA[Intro to Computational Media]]></category>

		<guid isPermaLink="false">http://www.pixelpunchout.com/?p=360</guid>
		<description><![CDATA[For my ICM Web proposal, I want to expand on my original Javascript/PHP application, Wearcaster. It&#8217;s designed to help users quickly see what outfits they should wear based on their destination weather/temperature conditions. As a South Floridian, I was clueless about how to dress for New York&#8217;s changing seasons from the hot summer to colder [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/10/picture-21.png" title="picture-21" rel="lightbox[360]"><img class="alignnone size-full wp-image-337" title="picture-21" src="http://www.pixelpunchout.com/wp-content/uploads/2009/10/picture-21.png" alt="picture-21" width="500" height="377" /></a></p>
<p>For my ICM Web proposal, I want to expand on my original Javascript/PHP application, <a href="http://itp.nyu.edu/~cw1028/icmw/week5/week5labzip2.php" target="_blank">Wearcaster</a>. It&#8217;s designed to help users quickly see what outfits they should wear based on their destination weather/temperature conditions. As a South Floridian, I was clueless about how to dress for New York&#8217;s changing seasons from the hot summer to colder autumn. Living up on a 5th floor walk-up apartment, I often quickly glanced at the weather websites, figured out an outfit, and walked downstairs to start my day. Oftentimes, I was underprepared and was too far in my commute to go back home and change. After sharing Wearcaster with friends and acquaintances, I heard similar stories and also received feedback that let me think of how to expand its original application.</p>
<p>For my Midterm, I&#8217;d like to expand on WearCaster in a few ways:</p>
<p><strong>1) Expand it outside New York City:</strong> Make the website and it&#8217;s weather suggestions  accessible to users in other destinations within the United States. Using PHP, Wearcaster would have a zip code submit form so users can get customized weather/wardrobe information, whether it&#8217;s New York, San Francisco, or Miami.</p>
<p><strong>2) Guy or Girl Friendly</strong>: WearCaster would give you different results depending if you identified yourself as a guy or girl.</p>
<p><strong>3) User Clothing Input:</strong> Website visitors would have the option to either see Wearcaster&#8217;s suggested clothing (through a sponsored fashion brand, like Anthropologie, Urban Outfitters, Gap, etc.) or they can use Wearcaster to upload photos of their own clothing items and tag them appropriately (&#8220;jacket&#8221;, &#8220;coat&#8221;, &#8220;dress&#8221;, &#8220;blouse&#8221;). That way, users can define for themselves what clothing is appropriate for which temperature climate.</p>
<p><strong>4) Fine tune Weather variables:</strong> So far, Wearcaster pulls Yahoo! Weather&#8217;s API data for temperature alone. I had roughly made 4 classifications but I will have to expand to take into account more temperature variations around the US. For example, hot weather is only currently defined for anything above 70degrees! It should also take into account rain predictions so people would know to bring an umbrella with them before they leave the house also.</p>
<p style="padding-left: 30px;">Addendum?  May choose to offer multi-day wardrobe suggestion pending what RSS data is available through other weather provider websites.</p>
<p><em>Ideal users for Wearcaster:</em> Travelers, New City residents (unused to the cold), People who dislike spending time assembling outfits for themselves</p>
<p><em>Purpose:</em> The web app allowed users to see very easily what they should wear today based on the weather/temperature conditions.</p>
<p><em>Applications: </em>Wardrobe suggestions, Weather reader, Travel Packing</p>
<p>Here are the wireframes I&#8217;ve generated for the different interactions below:</p>

<a href='http://pixelpunchout.com/2009/10/icm-web-midterm-proposal/homepage/' ><img width="150" height="150" src="http://pixelpunchout.com/wp-content/uploads/2009/10/homepage-150x150.jpg" class="attachment-thumbnail" alt="homepage" title="homepage" /></a>
<a href='http://pixelpunchout.com/2009/10/icm-web-midterm-proposal/reading/' ><img width="150" height="150" src="http://pixelpunchout.com/wp-content/uploads/2009/10/reading-150x150.jpg" class="attachment-thumbnail" alt="display page" title="display page" /></a>
<a href='http://pixelpunchout.com/2009/10/icm-web-midterm-proposal/customized/' ><img width="150" height="150" src="http://pixelpunchout.com/wp-content/uploads/2009/10/customized-150x150.jpg" class="attachment-thumbnail" alt="customized" title="customized" /></a>

<p><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/10/homepage.jpg" title="homepage" rel="lightbox[360]"><img class="alignnone size-medium wp-image-366" title="homepage" src="http://www.pixelpunchout.com/wp-content/uploads/2009/10/homepage-300x172.jpg" alt="homepage" width="300" height="172" /></a><br />
<strong>Home Page: PHP</strong><br />
1. Select Your Gender<br />
// Generate Radio Buttons.<br />
2. Enter Zip Code to see your local Wearcast report. Press GO button.<br />
// Generate Submit Form, Go Button. GO () function works when all fields are selected/filled out.</p>
<p>// This information is generated via a process.php + display.php combined on same php file.</p>
<p>GO function = Sources Yahoo! API weather. Checks for temperature, rain precipitation, UV(?) factors.</p>
<p>Processes results to display page next.</p>
<p><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/10/reading.jpg" title="display page" rel="lightbox[360]"><img class="alignnone size-medium wp-image-367" title="display page" src="http://www.pixelpunchout.com/wp-content/uploads/2009/10/reading-300x179.jpg" alt="display page" width="300" height="179" /></a><br />
<strong>Display Page Results:<br />
</strong><br />
1. Variables are organized in arrays: temperature readings, location, advice.<br />
Based on temperature/weather conditions, the arrays will present the wardrobe needed. For variety, the images may be randomized per their category (&#8220;shirts&#8221;, &#8220;jackets&#8221;, etc). Not sure to go that route.</p>
<p>//Set up variables, set up arrays for advice generated, city name displayed, temperature/date/time displayed. May</p>
<p>2. Set up links for alternate wardrobe selections to display: GAP vs. Urban Outfitters wardrobe.<br />
//Same formula. Just set  up different arrays (Gap, Anthropolgie) on a new page clicked.</p>
<p><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/10/customized.jpg"><br />
<img class="alignnone size-medium wp-image-365" title="customized" src="http://www.pixelpunchout.com/wp-content/uploads/2009/10/customized-300x186.jpg" alt="customized" width="300" height="186" /></a><br />
<strong>3. Optional (May Work for a Final?):</strong> If users could upload their own wardrobe photos to a database that recognizes<br />
their unique ID (sign-in?) that way users can get their own randomized wardrobe suggestions based on weather factors.</p>
]]></content:encoded>
			<wfw:commentRss>http://pixelpunchout.com/2009/10/icm-web-midterm-proposal/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Serial Out with Arduino (Javascript Edition)</title>
		<link>http://pixelpunchout.com/2009/10/serial-out-with-arduino-javascript-edition/</link>
		<comments>http://pixelpunchout.com/2009/10/serial-out-with-arduino-javascript-edition/#comments</comments>
		<pubDate>Thu, 15 Oct 2009 02:27:18 +0000</pubDate>
		<dc:creator>Cindy</dc:creator>
				<category><![CDATA[ITP]]></category>
		<category><![CDATA[Intro to Computational Media]]></category>
		<category><![CDATA[Physical Computing]]></category>

		<guid isPermaLink="false">http://www.pixelpunchout.com/?p=346</guid>
		<description><![CDATA[For this lab assignment, I learned how to set up an interaction between my Arduino and my computer.  This is called serial communication.  I hooked up a variable resistor, my pentiometer, to my breadboard. From there, I set up my USB between my computer and  Arduino. Data from my pentiometer travels to the Arduino who [...]]]></description>
			<content:encoded><![CDATA[
<a href='http://pixelpunchout.com/2009/10/serial-out-with-arduino-javascript-edition/picture-17/' ><img width="150" height="150" src="http://pixelpunchout.com/wp-content/uploads/2009/10/picture-17-150x150.png" class="attachment-thumbnail" alt="picture-17" title="picture-17" /></a>
<a href='http://pixelpunchout.com/2009/10/serial-out-with-arduino-javascript-edition/picture-14/' ><img width="150" height="150" src="http://pixelpunchout.com/wp-content/uploads/2009/10/picture-14-150x150.png" class="attachment-thumbnail" alt="picture-14" title="picture-14" /></a>
<a href='http://pixelpunchout.com/2009/10/serial-out-with-arduino-javascript-edition/picture-13/' ><img width="150" height="150" src="http://pixelpunchout.com/wp-content/uploads/2009/10/picture-13-150x150.png" class="attachment-thumbnail" alt="picture-13" title="picture-13" /></a>
<a href='http://pixelpunchout.com/2009/10/serial-out-with-arduino-javascript-edition/picture-11-2/' ><img width="150" height="150" src="http://pixelpunchout.com/wp-content/uploads/2009/10/picture-11-150x150.png" class="attachment-thumbnail" alt="picture-11" title="picture-11" /></a>
<a href='http://pixelpunchout.com/2009/10/serial-out-with-arduino-javascript-edition/picture-10/' ><img width="150" height="150" src="http://pixelpunchout.com/wp-content/uploads/2009/10/picture-10-150x150.png" class="attachment-thumbnail" alt="picture-10" title="picture-10" /></a>
<a href='http://pixelpunchout.com/2009/10/serial-out-with-arduino-javascript-edition/picture-16/' ><img width="150" height="150" src="http://pixelpunchout.com/wp-content/uploads/2009/10/picture-16-150x150.png" class="attachment-thumbnail" alt="picture-16" title="picture-16" /></a>
<a href='http://pixelpunchout.com/2009/10/serial-out-with-arduino-javascript-edition/picture-15/' ><img width="150" height="150" src="http://pixelpunchout.com/wp-content/uploads/2009/10/picture-15-150x150.png" class="attachment-thumbnail" alt="picture-15" title="picture-15" /></a>

<p>For this lab assignment, I learned how to set up an interaction between my Arduino and my computer.  This is called serial communication.  I hooked up a variable resistor, my pentiometer, to my breadboard. From there, I set up my USB between my computer and  Arduino. Data from my pentiometer travels to the Arduino who transmits it to my computer to display in a visual interface on my web browser (via a Javascript applet).  This Javascript applet graphs my sensor&#8217;s output corresponding with my action with my pentiometer . See the screenshots above from multiple takes.</p>
<p>FYI:</p>
<p>Prof. Shawn Van Every created the<a href="http://www.walking-productions.com/jsserial/new/JSSerial.html" target="_blank"> Javascript application</a>. Links and installation steps <a href="http://www.walking-productions.com/jsserial/new/JSSerial.html" target="_blank">here</a>.</p>
<p>Tip: When it comes to sensing your data over  serial communication, it&#8217;s a good idea to troubleshoot your setup. On my Arduino, I input this code below:</p>
<pre><span style="color: #cc6600;">int</span> analogPin = 0;
 <span style="color: #cc6600;">int</span> analogValue = 0;

 <span style="color: #cc6600;">void</span> <span style="color: #cc6600;"><strong>setup</strong></span>()
 {
   <span style="color: #7e7e7e;">// start serial port at 9600 bps:</span>
   <span style="color: #cc6600;">Serial</span>.<span style="color: #cc6600;">begin</span>(9600);
 }

 <span style="color: #cc6600;">void</span> <span style="color: #cc6600;"><strong>loop</strong></span>()
 {
   <span style="color: #7e7e7e;">// read analog input, divide by 4 to make the range 0-255:</span>
   analogValue = <span style="color: #cc6600;">analogRead</span>(analogPin);
   analogValue = analogValue / 4;
   <span style="color: #cc6600;">Serial</span>.<span style="color: #cc6600;">print</span>(analogValue, <span style="color: #006699;">BYTE</span>);
   <span style="color: #7e7e7e;">// pause for 10 milliseconds:</span>
   <span style="color: #cc6600;">delay</span>(10);
 }</pre>
<p>From there, I check my serial monitor to see the ASCII characters in play when I twist my pentiometer. I, then modify the code from BYTE to DEC to see the numerical values. Is it working? Yes?</p>
<p>Problems Encountered: Faulty/Buggy Javascript app code that was later modified by Prof Shawn + that later allowed me to show the different feedback results from my Pentiometer test.</p>
<p>REVISED: Prof. Shawn Van Every released an updated version of Javascript applet here that is much more sensitive to the Arduino output. <a href="http://www.walking-productions.com/jsserial/new/new_serial_graph.html" target="_blank">New Serial Graph link.</a></p>
<p>Future tip: If I plan to do any visual display work with Javascript and Arduino, I need to include  the following files: <a href="http://www.walking-productions.com/jsserial/new/JSSerial.jar">JSSerial.jar</a> and <a href="http://www.walking-productions.com/jsserial/new/jsserial-applet.jnlp">jsserial-applet.jnlp</a> along with my HTML/JavaScript.</p>
<p>For ICM Web, we had to create our own Javascript web applet. Here&#8217;s my output with my pentiometer.<br />
<object width="500" height="375" data="http://vimeo.com/moogaloop.swf?clip_id=7148797&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=00ADEF&amp;fullscreen=1" type="application/x-shockwave-flash"><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://vimeo.com/moogaloop.swf?clip_id=7148797&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=00ADEF&amp;fullscreen=1" /></object></p>
<p><a href="http://vimeo.com/7148797">Serial Communication with the Arduino</a> from <a href="http://vimeo.com/user758179">cindy wong</a> on <a href="http://vimeo.com">Vimeo</a>.</p>
<p><span style="font-family: Lucida Grande; font-style: normal; font-variant: normal; font-weight: normal; font-size: medium; line-height: normal; font-size-adjust: none; font-stretch: normal;">&lt;pre class=&#8221;postCode&#8221;&gt;</span></p>
<pre id="line1">&lt;<span class="start-tag">html</span>&gt;
	&lt;<span class="start-tag">head</span>&gt;
		&lt;<span class="start-tag">title</span>&gt; Serial Communication: Experimenting with Pentiometer, Loops &lt;/<span class="end-tag">title</span>&gt;
		<span class="comment">&lt;!-- Change Colors --&gt;</span>

		&lt;<span class="start-tag">style</span><span class="attribute-name"> type </span>=<span class="attribute-value"> "text/css"</span>&gt;

		body	{
		font-family: Arial Black, Arial, Helvetica, Sans-Serif;
		font-size: 55pt;
		}

		#body	{
		background-color: #000000; /* starts black */
		}

		&lt;/<span class="end-tag">style</span>&gt;

&lt;<span class="start-tag">script</span><span class="attribute-name"> type </span>=<span class="attribute-value"> "text/javascript"</span>&gt;

		function initVars()
			{
				thecolordiv = document.getElementById("colordiv"); //swap words
			}
		function openPort()
		{
		document.JSSerial.startSerial("/dev/tty.usbserial-A6008nhi");
		//hardwires the USB serial port connection 

		//myinterval = setInterval("readSerial()",5);
		//sets Interval delay, PC delay has to be faster then Arduino code delay

		startTimer();
		}

		function startTimer()
		// function to kick off timer.
		{
			var timer = setInterval("timerran()",5);
			//PC has shorter delay then Arduino
		}

		function timerran()
		{
			//tests if data is available
			if (document.JSSerial.available() &gt; 0)
			{
				//var outputdivtimer = document.getElementById("outputdivtimer");
				//turns it into a variable

				// reads the sensor's bytes from the serial port
				var inByte = document.JSSerial.last();

				// write sensor values (bytes) to the output div
				//outputdivtimer.innerHTML = inByte;

	// pseudo code time!

			if ((inByte &gt;= 0) &amp;&amp; (inByte &lt; 50))
			{
			// Change the "style" of the body and set the background color to red
			document.body.style.backgroundColor = "#FF0000";
			colordiv.innerHTML = "RED";
			//SAY RED, CHANGE TO RED
			}

			if ((inByte &gt;= 50) &amp;&amp; (inByte &lt; 60))
			{
			document.body.style.backgroundColor = "#FF3300";
			colordiv.innerHTML = "ORANGE";
			//say ORANGE, TURN ORANGE
			}

 			if ((inByte &gt;= 60) &amp;&amp; (inByte &lt; 70))
 			{

 			document.body.style.backgroundColor = "#FFCC00";
			colordiv.innerHTML = "YELLOW";
			//say YELLOW, TURN YELLOW
 			}

 			if ((inByte &gt;= 70) &amp;&amp; (inByte &lt; 80))
 			{
 			document.body.style.backgroundColor = "#99FF00";
			colordiv.innerHTML = "GREEN";
 			// say GREEN, TURN GREEN
 			}

			if ((inByte &gt;= 80) &amp;&amp; (inByte &lt; 90))
			{
			document.body.style.backgroundColor = "#00CCFF";
			colordiv.innerHTML = "BLUE";
			// say BLUE, turn BLUE
			}

			if ((inByte &gt;= 90) &amp;&amp; (inByte &lt; 100))
			{
			document.body.style.backgroundColor = "#6600CC";
			colordiv.innerHTML = "PURPLE";
			// say PURPLE, turn PURPLE
			}

			if ((inByte &gt;= 100) &amp;&amp; (inByte &lt;110))
			{
			document.body.style.backgroundColor = "#666666";
			colordiv.innerHTML = "GRAY";
			//say GRAY, turn GRAY
			}

			if ((inByte &gt;= 110) &amp;&amp; (inByte &lt; 127))
			{
			document.body.style.backgroundColor = "#000000";
			colordiv.innerHTML = "BLACKNESS";
			// say BLACK, turn BLACK
			}
		}
		}
&lt;/<span class="end-tag">script</span>&gt;
&lt;/<span class="end-tag">head</span>&gt;</pre>
<pre id="line122">
&lt;<span class="start-tag">body</span><span class="attribute-name"> onload</span>=<span class="attribute-value">"initVars()"</span>&gt;
		<span class="comment">&lt;!-- The Applet which provides serial port access, should be in the body --&gt;</span>
		&lt;<span class="start-tag">script</span><span class="attribute-name"> src</span><span>="</span><a href="view-source:http://www.java.com/js/deployJava.js">http://www.java.com/js/deployJava.js</a><span>"</span>&gt;&lt;/<span class="end-tag">script</span>&gt;
		&lt;<span class="start-tag">script</span>&gt;
			var attributes = { code:'JSSerial.class', archive:'JSSerial.jar',  width:1, height:1, id:'JSSerial'};
			var parameters = {jnlp_href: 'jsserial-applet.jnlp'};
			deployJava.runApplet(attributes, parameters, '1.5');
		&lt;/<span class="end-tag">script</span>&gt;

		<span class="comment">&lt;!-- Done with the applet --&gt;</span>

<span class="comment">&lt;!-- START Button IGNITES COLOR CHANGE CONTROLLED BY POT VALUES --&gt;</span>
&lt;<span class="start-tag">input</span><span class="attribute-name"> type</span>=<span class="attribute-value">"button" </span><span class="attribute-name">name</span>=<span class="attribute-value">"start me up" </span><span class="attribute-name">value</span>=<span class="attribute-value">"start" </span><span class="attribute-name">onclick</span>=<span class="attribute-value">"openPort()"</span><span class="attribute-name">;</span>&gt;</pre>
<pre id="line137"><span class="comment">&lt;!-- Serial Read Output:
&lt;div id="outputdivtimer"&gt; &lt;/div&gt; --&gt;</span> 

&lt;<span class="start-tag">h1</span>&gt; Color Output: &lt;/<span class="end-tag">h1</span>&gt;
&lt;<span class="start-tag">div</span><span class="attribute-name"> id</span>=<span class="attribute-value"> "colordiv"</span>&gt; Black &lt;/<span class="end-tag">div</span>&gt;

&lt;/<span class="end-tag">body</span>&gt;
&lt;/<span class="end-tag">html</span>&gt;</pre>
<p>&lt;/pre&gt;</p>
]]></content:encoded>
			<wfw:commentRss>http://pixelpunchout.com/2009/10/serial-out-with-arduino-javascript-edition/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Wearcaster: What Should I Wear Today?</title>
		<link>http://pixelpunchout.com/2009/10/338/</link>
		<comments>http://pixelpunchout.com/2009/10/338/#comments</comments>
		<pubDate>Mon, 12 Oct 2009 01:18:28 +0000</pubDate>
		<dc:creator>Cindy</dc:creator>
				<category><![CDATA[ITP]]></category>
		<category><![CDATA[Intro to Computational Media]]></category>

		<guid isPermaLink="false">http://www.pixelpunchout.com/?p=338</guid>
		<description><![CDATA[So, for learning PHP, I decided to make a little fashion/weather mashup. Meet Wearcaster, the app that pulls up New York City temperature readings (from Yahoo! Weather RSS feed) and based on my parameters, let&#8217;s me know what I need to wear before I step out the door. Now, you may ask, Cindy, aren&#8217;t you [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/10/picture-21.png"></a><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/10/picture-21.png" title="picture-21" rel="lightbox[338]"><img class="alignnone size-full wp-image-337" title="picture-21" src="http://www.pixelpunchout.com/wp-content/uploads/2009/10/picture-21.png" alt="picture-21" width="500" height="377" /></a></p>
<p>So, for learning PHP, I decided to make a little fashion/weather mashup. Meet <strong><a href="http://itp.nyu.edu/~cw1028/icmw/week5/week5labzip2.php" target="_blank">Wearcaster</a></strong>, the app that pulls up New York City temperature readings (from Yahoo! Weather RSS feed) and based on my parameters, let&#8217;s me know what I need to wear before I step out the door.</p>
<p>Now, you may ask, Cindy, aren&#8217;t you lazy? Can&#8217;t you just tell from the weather temperature reading alone? And I say, no. I&#8217;m a Florida girl. My understanding of cold weather is still developing. What&#8217;s the difference between 65 vs 55? Cardigan or hoodie or coat? Plus, I live on the 5th floor so if I&#8217;m walking a few blocks down and I realize I&#8217;m under dressed, I&#8217;m way too lazy to walk back and put on a thicker jacket. It&#8217;s 5 floors people!</p>
<p>Thus, why for people who are unused to the cold, and all the fashion gradients in between, I&#8217;ve made this for you (meaning me).</p>
]]></content:encoded>
			<wfw:commentRss>http://pixelpunchout.com/2009/10/338/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Intro to Computational Media: Meet the ITP Fortune Cookie Teller</title>
		<link>http://pixelpunchout.com/2009/10/intro-to-computational-media-meet-the-itp-fortune-cookie-teller/</link>
		<comments>http://pixelpunchout.com/2009/10/intro-to-computational-media-meet-the-itp-fortune-cookie-teller/#comments</comments>
		<pubDate>Wed, 07 Oct 2009 18:06:36 +0000</pubDate>
		<dc:creator>Cindy</dc:creator>
				<category><![CDATA[ITP]]></category>
		<category><![CDATA[Intro to Computational Media]]></category>

		<guid isPermaLink="false">http://www.pixelpunchout.com/?p=333</guid>
		<description><![CDATA[Feeling down? Need an encouraging note while you&#8217;re down in the dumps? Try the ITP Fortune Cookie Teller. Designed to test my knowledge of arrays within Javascript, my class assignment was to make something fun. Hello, positive encouragement! Who doesn&#8217;t like a free cookie?]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.pixelpunchout.com/wp-content/uploads/2009/10/picture-2.png" title="picture-2" rel="lightbox[333]"><img class="alignnone size-medium wp-image-334" title="picture-2" src="http://www.pixelpunchout.com/wp-content/uploads/2009/10/picture-2-293x300.png" alt="picture-2" width="293" height="300" /></a></p>
<p>Feeling down? Need an encouraging note while you&#8217;re down in the dumps? <a href="http://itp.nyu.edu/~cw1028/icmw/week4/funlab/week4funlab.html" target="_blank">Try the ITP Fortune Cookie Teller</a>. Designed to test my knowledge of arrays within Javascript, my class assignment was to make something fun. Hello, positive encouragement! Who doesn&#8217;t like a free cookie?</p>
]]></content:encoded>
			<wfw:commentRss>http://pixelpunchout.com/2009/10/intro-to-computational-media-meet-the-itp-fortune-cookie-teller/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
