<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-411157468520755607</id><updated>2011-06-07T23:46:19.195-07:00</updated><title type='text'>MiXem</title><subtitle type='html'>You control the music</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://pseq.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://pseq.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>myg3000</name><uri>http://www.blogger.com/profile/02275784179300760298</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>13</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-411157468520755607.post-5949936142549163223</id><published>2007-12-16T01:00:00.000-08:00</published><updated>2007-12-16T01:04:30.649-08:00</updated><title type='text'>MiXem in action!</title><content type='html'>&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-13b5cf9cd36f915a" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v16.nonxt4.googlevideo.com/videoplayback?id%3D13b5cf9cd36f915a%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1329907328%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D3BDECE103CEE0CA02675116A43DCC9FA09DEDB83.7570D5773D327C89D52C456A379F0784707F47D0%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D13b5cf9cd36f915a%26offsetms%3D5000%26itag%3Dw160%26sigh%3DDMNKXnk04MZuGSxATQMzVtP0_mQ&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v16.nonxt4.googlevideo.com/videoplayback?id%3D13b5cf9cd36f915a%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1329907328%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D3BDECE103CEE0CA02675116A43DCC9FA09DEDB83.7570D5773D327C89D52C456A379F0784707F47D0%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D13b5cf9cd36f915a%26offsetms%3D5000%26itag%3Dw160%26sigh%3DDMNKXnk04MZuGSxATQMzVtP0_mQ&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/411157468520755607-5949936142549163223?l=pseq.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=13b5cf9cd36f915a&amp;type=video%2Fmp4' length='0'/><link rel='replies' type='application/atom+xml' href='http://pseq.blogspot.com/feeds/5949936142549163223/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=411157468520755607&amp;postID=5949936142549163223' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/5949936142549163223'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/5949936142549163223'/><link rel='alternate' type='text/html' href='http://pseq.blogspot.com/2007/12/mixem-in-action.html' title='MiXem in action!'/><author><name>Jose Olivares</name><uri>http://www.blogger.com/profile/04515616948499092048</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-411157468520755607.post-1712827763736305628</id><published>2007-12-15T22:38:00.000-08:00</published><updated>2007-12-15T23:42:05.359-08:00</updated><title type='text'>Jose Olivares' notes (MIDI/code/Ableton)</title><content type='html'>So in this post I'll talk a bit about the project in general, my introduction to the world of MIDI via coding and using Ableton live in ways that I've never tried up until this point. In my blog you'll find pictures, videos and coding examples.&lt;br /&gt;&lt;br /&gt;The MiXem started out as  continuation to our physical midterm project. For that project I worked with Matt Young and HeeJin Joo. Basically the midterm was called Sonic Cubes and consisted of acrylic cubes that would trigger sound and light up inside. We used three cubes (due to time constraints) and spent a lot of time on the design, specifically trying to achieve a very clean and simple interface.&lt;br /&gt;&lt;br /&gt;After that midterm was done we all decided to keep working on it and this time make some new improvements to them such as having them send wireless data, visual feedback, expressive sound controls and more cubes overall. So I was very happy to learn that Tymm Twillmann wanted to join our team, and then later on he invited Dave Spector to join the team so that meant we had another musician in the group.&lt;br /&gt;&lt;br /&gt;As Matt and Tymm already stated, we met for the first couple of weeks to try to decide what we actually wanted to do and how to do it. Conflicts of schedule, and the fact that we were so many in the group made these meetings hard to organize, but I think that considering the number of times we got together we came out with a very good idea. Ever since Matt, HeeJin and I started to work together we really wanted to do something that had to do with my music and real-time controls. The original purpose of the MiXem was to make it a device that I could take on the road and play with my band. I was very honored that my team wanted to do this, as it meant creating a custom-built instrument that I can use.&lt;br /&gt;&lt;br /&gt;And it was this process of trying to define the project where we spent a lot of time, and we all had to talk extensively about it. Was this project going to be a musical instrument or a MIDI interface? That was the question that took weeks to answer. Since the set-up of my band deals with electronic and acoustic instruments, and I spend a lot of time working with my laptop during the live performances, I was more inclined towards the MIDI interface approach since it's something that is very flexible and can serve different purposes depending on how you set it up. When working live with my laptop I do a lot of sound processing and manipulation, and that's something that I wanted to incorporate in the project that could be used in my live shows or as part of a sound installation where the visitor can interact with the sounds being played back. Dave also proposed the idea of doing a sequencer-type device where the user can build his/her own song on the fly and have the control to select the instruments he/she wants for that song. I also liked the idea, but with the design that we had at that moment (using cubes on a grid) it seemed like something that could be kind of confusing and that it wouldn't serve effectively the sound processing aspect, but we didn't discard that functionality at all. I also liked the idea of having controls to change the sound because that was something that we also wanted to link with the visual aspect.&lt;br /&gt;&lt;br /&gt;So after a few weeks of trying to define the device, we got to a point where we had to say exactly what the project was going to be because at that point we've been going back and forth between instrument, sequencer, audio-visual installation, or MIDI controller. At the beginning I didn't understand very well Dave's proposal of how he thought the machine could work, and I had a hard time trying to fit that with the rest of our ideas, specifically sound and visual manipulation . Tymm brought the possibility of using sensors similar to iPod scrollwheel where we could trigger loops and also manipulate sound. I thought that our problem was solved there, but then began the logistics nightmare of making that interface talk with Processing to handle the a/v side. From my previous attempt at working with sound in Processing I knew that the sound libraries where not that good for what we wanted to do. So I suggested using MIDI and bypassing Processing in favor of working with Ableton Live which is the software that use when I play live and that I most comfortable with. With this decision also came the final stage f defining the instrument when I decided to work with Dave's idea of a sequencer since this is something that I can also use and it meant that I would have to try a new performance/composition approach that I wanted to do for a while. Now theinterface design consisted of 8 sensors that would handle 56 loops, spread across 8 instruments.&lt;br /&gt;&lt;br /&gt;Very good. The next step was then figuring out how to send data from the Arduino to Ableton live. I was aware that Tom Igoe had a MIDI out lab in his website but I only thought that would only work with external synth modules and not software. One day looking through the ITP blogs I saw that someone sent MIDI note messages to Garageband. That was very helpful, so Matt and I decided to do the MIDI lab. And by using a MIDISport 2 X2 box we sent MIDI data to Garageband, and it worked. The next step was to learn then how to send continuous controller messages because we where going to work with event handling and not note-ons/note-offs. With a lot of help from Tymm we set-up a code in the Arduino that would identify three pots as CCs and they would send sensor data via MIDI (Channel 0) to Ableton using. They worked very good, but we had some issues with the sensor values not being stable and the would fluctuate a bit when we hooked them up to parameters controls such reverb decay, resonance amouunt, etc. But since the project consisted of only triggering sounds, we knew that switches would work very good and they would be stable.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-9d5a6e76ab8a7cd1" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v12.nonxt7.googlevideo.com/videoplayback?id%3D9d5a6e76ab8a7cd1%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1329907328%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D731DC3ED8B690AEE7AC085B24A889BD33BE17E78.1FE9B69CFF4F1F346D5BA7C364634E545F975902%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D9d5a6e76ab8a7cd1%26offsetms%3D5000%26itag%3Dw160%26sigh%3DOe5WEHOU-vTV7Kv8RTYHUuvozwI&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v12.nonxt7.googlevideo.com/videoplayback?id%3D9d5a6e76ab8a7cd1%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1329907328%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D731DC3ED8B690AEE7AC085B24A889BD33BE17E78.1FE9B69CFF4F1F346D5BA7C364634E545F975902%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D9d5a6e76ab8a7cd1%26offsetms%3D5000%26itag%3Dw160%26sigh%3DOe5WEHOU-vTV7Kv8RTYHUuvozwI&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;br /&gt;&lt;br /&gt;At this point, I then started working with Dave on setting up a series of switches that would trigger loops depending on the state they where. This was by far the hardest part of the project. Being myself not very fluent in programming I had a hard time trying to grasp the logic of "if statements", "for loops" and states. I'm very used to directly hooking up things and just make them work directly on the interface without having to resort to any code. We started out with 4 switches that would, in theory, send 16 different CC messages such as instrument selection, loop selection, and loop muting. The way that the switches had to work meant that we had to state what was the first switch pressed and then the second switch pressed so that we can trigger a loop, and that if let go of the the both of them they would go back to a state where the program resets and you can do this all over again and trigger the loop that you want in another instrument. Another nightmare. We had a LOT of issues with this mainly because we didn't know how to tell the program to handle this. And on top of that we also had to figure out how to define each event with a particular continuous controller number that we could use to define in Ableton what loop we wanted to trigger. We spent weeks and weeks working on this mainly because the code needed more things that we didn't know. Also there where two things that made the integration with Ableton live very difficult and that was that Dave wanted a switch to send more than one CC message. For those not very familiar with Ableton Live and the way it handles the MIDI mapping is by going into a mode where to map each controller you just select the Edit Map option, select your parameter and then move your knob (or anything else) in your controller. It's done one by one and you can't manually input the CC number to a parameter, you have to send it from your controller. Because the logic behind our switches wasn't working very well we had to make the code work so that we can then do the MIDI mapping. Also Dave wanted to include an option where the user can go from one song to another. This meant then that we needed to add two more or switches or make the switches handle more than one thing. Again, another nightmare. This time because a trigger would have to select an instrument, trigger a loop, mute the loop and select another song and then control those other loops.  We are talking about 4 different MIDI messages coming from the same trigger.&lt;br /&gt;&lt;br /&gt;The next phase was when we started to cut out features and make the device easier to understand and to program. I thought that 56 loops for one song was too much, and that we only should have 6 circles. I also thought that it was better to have separate sensors to do the song selection, and to add a silent loop to each instrument and that could serve as our mute button. This made a bit easier the code, but still it was a hard task. Dave thought of making states so that we can define what was happening when a person would hold one switch and then another switch at the same time. We had to consider several factors such as the order in which the switches where pressed, what would happen if a person triggered the same switch twice, how to make these switches go from controlling one song to another and how to incorporate a mute button per instrument. After working a lot with Matt Parker he suggested the idea of using a 6X6 two-dimensional array so that for each song the switches would have a particular CC number if pressed in a particular order, so that they don't repeat. That was good because we had a problem where if you press switch 1 and then 4, it would be the same as pressing 4 and then 1. The way it ended working is that the program would constantly look for the input of the first and the second switch pressed and then depending on that it would look up a cc value in the 2-d array and then if this combination of switches corresponded to a particular state then it would send a message as a specific CC number. If you then switched to other song it would do the same but the program would add 36 to the CC number so that it's not confused with the first song. And by switching from one song to another we programmed these sensors that handle this to send a CC number to global loop stop command.&lt;br /&gt;&lt;br /&gt;Arduino code:&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;#define CHANNEL 0x00&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;// Variables:&lt;br /&gt;&lt;br /&gt;int state = 1;&lt;br /&gt;int loopActive = -1;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;boolean daveSong = false;&lt;br /&gt;&lt;br /&gt;int firstPressed = -1;&lt;br /&gt;int secondPressed = -1;&lt;br /&gt;int musical_Array [6][6]={&lt;br /&gt;  {&lt;br /&gt;    1,7, 8, 9,10,11  }&lt;br /&gt;  ,&lt;br /&gt;  {&lt;br /&gt;    12,2,13,14,15,16  }&lt;br /&gt;  ,&lt;br /&gt;  {&lt;br /&gt;    17,18,3,19,20,21  }&lt;br /&gt;  ,&lt;br /&gt;  {&lt;br /&gt;    22,23,24,4,25,26  }&lt;br /&gt;  ,&lt;br /&gt;  {&lt;br /&gt;    27,28,29,30,5,31  }&lt;br /&gt;  ,&lt;br /&gt;  {&lt;br /&gt;    32,33,34,35,36,6  }&lt;br /&gt;   &lt;br /&gt;};&lt;br /&gt;&lt;br /&gt;int DigitalValue1 = 0;&lt;br /&gt;int DigitalValue2 = 0;         // value from thedigital input&lt;br /&gt;&lt;br /&gt;int ledPin = 13;&lt;br /&gt;&lt;br /&gt;void setup() {&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;  pinMode(13, INPUT);&lt;br /&gt;  pinMode(12, INPUT);&lt;br /&gt;  tlc5940_init();&lt;br /&gt;   Serial.begin(31250);&lt;br /&gt;  //  set the states of the I/O pins:&lt;br /&gt;  // pinMode(switchPin, INPUT);&lt;br /&gt;  //Serial.begin(9600);&lt;br /&gt; // pinMode(ledPin, OUTPUT);&lt;br /&gt;  //  Set MIDI baud rate:&lt;br /&gt; // blink(3);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;void sendController(char controller_num, char controller_val)&lt;br /&gt;{&lt;br /&gt;  Serial.print(0xB0 | CHANNEL, BYTE);  // MIDI Channel 0&lt;br /&gt;  Serial.print(controller_num, BYTE); // Midi controller #&lt;br /&gt;  Serial.print(controller_val, BYTE); // Value of the MIDI controller&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;// Blinks an LED 3 times&lt;br /&gt;//void blink(int howManyTimes) {&lt;br /&gt;//  int i;&lt;br /&gt;//  for (i=0; i&lt; howManyTimes; i++) {&lt;br /&gt;//    digitalWrite(ledPin, HIGH);&lt;br /&gt;//    delay(100);&lt;br /&gt;//    digitalWrite(ledPin, LOW);&lt;br /&gt;//    delay(100);&lt;br /&gt;//  }&lt;br /&gt;//}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;void loop(){&lt;br /&gt; &lt;br /&gt;  if (state == 1) {  //state 1 waits for you to press a button&lt;br /&gt;    loopActive = -1;&lt;br /&gt;  //  Serial.println("you are in beatiful state 1");&lt;br /&gt;    for (int i = 5; i &lt; 11; i++){  //keep checking our pins to see if anything has been pressed&lt;br /&gt;      DigitalValue1 = digitalRead(i);  //read the number we are on (pins 5 to 12)&lt;br /&gt;&lt;br /&gt;      if (DigitalValue1 == HIGH){   //if you push a switch&lt;br /&gt;        if (i == 9) {&lt;br /&gt;          state = 7;&lt;br /&gt;        }&lt;br /&gt;        else if (i == 10) {&lt;br /&gt;          state = 8;&lt;br /&gt;        }&lt;br /&gt;        else {&lt;br /&gt;          firstPressed = (i-5);  //assign the value of i as first pressed (we subtract 5 to match the values of our array(for example 8-5 = value 3))&lt;br /&gt;    //    Serial.println("The first button is:");&lt;br /&gt;      //  Serial.println(firstPressed);&lt;br /&gt;        state = 2;  //you pressed a button/chose an instrument&lt;br /&gt;     //   delay(400);&lt;br /&gt;        }&lt;br /&gt;      }&lt;br /&gt;    }&lt;br /&gt;  }&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;  else if (state == 2) {    //state two waits for you to press a second button&lt;br /&gt;  //  Serial.println("you are in lovely state 2");&lt;br /&gt;&lt;br /&gt;    for (int i = 5; i &lt; 9; i++){  //keep checking to see if anything has been pressed&lt;br /&gt;      DigitalValue2 = digitalRead(i); &lt;br /&gt;      DigitalValue1 = digitalRead(firstPressed+5);&lt;br /&gt;      if ((DigitalValue2 == HIGH) &amp;amp;&amp;amp; (i != (firstPressed + 5))){&lt;br /&gt;        secondPressed = (i-5);&lt;br /&gt;    //    Serial.println("The second button is:");&lt;br /&gt;      //  Serial.println(secondPressed);&lt;br /&gt;        //delay(400);&lt;br /&gt;        state = 3;  //you pressed a second button (chose a loop for that instrument)&lt;br /&gt;      }&lt;br /&gt;      if (DigitalValue1 == LOW) {&lt;br /&gt;        if (loopActive== -1) {&lt;br /&gt;          state = 6;&lt;br /&gt;        }&lt;br /&gt;        if (loopActive== 1) {&lt;br /&gt;          state=1;&lt;br /&gt;        }&lt;br /&gt;      }&lt;br /&gt;    }&lt;br /&gt;  }&lt;br /&gt;&lt;br /&gt;  else if (state == 3) {   //state 3 checks the array and sends the MIDI value to Ableton&lt;br /&gt;    //Serial.println("you are in magnificent state 3");&lt;br /&gt;    //Serial.println("THE VALUE IS: ");&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;    if (!daveSong) {   //if not daveSong&lt;br /&gt;      //Serial.println(musical_Array[secondPressed][firstPressed], DEC);&lt;br /&gt;      sendController(musical_Array[secondPressed][firstPressed], 127);  //set the Continuous Controller # to the value from the array&lt;br /&gt;      loopActive = 1;&lt;br /&gt;      //delay(1000);&lt;br /&gt;      state = 4;  //the MIDI signal was sent to Ableton--now wait for buttons to be released&lt;br /&gt;    }&lt;br /&gt;&lt;br /&gt;    else {   //else if dave song == true&lt;br /&gt;      //Serial.println(musical_Array[secondPressed][firstPressed] + 36, DEC);&lt;br /&gt;      sendController(musical_Array[secondPressed][firstPressed] + 36, 127);  //set the Continuous Controller # to the value from the array&lt;br /&gt;      loopActive = 1;&lt;br /&gt;      //delay(1000);&lt;br /&gt;      state = 4;  //the MIDI signal was sent to Ableton--now wait for buttons to be released&lt;br /&gt;    }&lt;br /&gt;  }&lt;br /&gt;&lt;br /&gt;  else if (state == 4) {  //state 4 waits for you to release a button&lt;br /&gt;    //Serial.println("you are in delightful state 4");&lt;br /&gt;    DigitalValue1 = digitalRead(firstPressed+5);&lt;br /&gt;    DigitalValue2 = digitalRead(secondPressed+5);&lt;br /&gt;    if (DigitalValue1 == HIGH) {&lt;br /&gt;      if (DigitalValue2 == LOW) {           &lt;br /&gt;        secondPressed = -1;&lt;br /&gt;        state = 2;&lt;br /&gt;      }     &lt;br /&gt;    }&lt;br /&gt;    if ((DigitalValue1 == LOW) &amp;amp;&amp;amp; (DigitalValue2 == HIGH)) {&lt;br /&gt;      firstPressed = -1;&lt;br /&gt;      state = 5;  //you let go of your instrument but still have the loop button pressed&lt;br /&gt;    }&lt;br /&gt;&lt;br /&gt;  }&lt;br /&gt;&lt;br /&gt;  else if (state == 5) {  //state 5 occurs if you released button 1 before button 2--it stops reading until you release button 2&lt;br /&gt;      //  Serial.println("it's state 5.  like it or get out");&lt;br /&gt;    DigitalValue2 = digitalRead(secondPressed+5);&lt;br /&gt;    if (DigitalValue2 == LOW) {&lt;br /&gt;      secondPressed = -1;&lt;br /&gt;      state = 1;  //you let go of both buttons----start checking again&lt;br /&gt;    }&lt;br /&gt;  }&lt;br /&gt;  else if (state == 6)  {  //state 6 mutes the instrument&lt;br /&gt;    //Serial.println("how did you get to state 6");&lt;br /&gt;   // sendController(musical_Array[firstPressed][firstPressed], 127);&lt;br /&gt;    //***tell the instrument to go to the muted loop******&lt;br /&gt;    firstPressed = -1;&lt;br /&gt;    loopActive = -1;&lt;br /&gt;    //delay(800);&lt;br /&gt;    state = 1;  //start over&lt;br /&gt;  }&lt;br /&gt;&lt;br /&gt;  else if (state == 7) {&lt;br /&gt;    //Serial.println("this is state 7");&lt;br /&gt;    daveSong = false;&lt;br /&gt;    //Serial.println("this is jose's song");&lt;br /&gt;    sendController(73, 127);&lt;br /&gt;    //delay(100);&lt;br /&gt;     for (int i = 9; i &lt; 11; i++){  //keep checking our pins to see if anything has been pressed&lt;br /&gt;      DigitalValue1 = digitalRead(i);  //read the number we are on (pins 5 to 12)&lt;br /&gt;&lt;br /&gt;     if (DigitalValue1 == LOW) {&lt;br /&gt;        state = 1;&lt;br /&gt;    }&lt;br /&gt;     }&lt;br /&gt;  }&lt;br /&gt;  else if (state == 8) {&lt;br /&gt;    //Serial.println("this is state 8");&lt;br /&gt;    daveSong = true;&lt;br /&gt;    //Serial.println("this is dave's song");&lt;br /&gt;    sendController(73, 127);&lt;br /&gt;    //delay(100);&lt;br /&gt;     for (int i = 9; i &lt; 11; i++){  //keep checking our pins to see if anything has been pressed&lt;br /&gt;      DigitalValue1 = digitalRead(i);  //read the number we are on (pins 5 to 12)&lt;br /&gt;&lt;br /&gt;     if (DigitalValue1 == LOW) {&lt;br /&gt;        state = 1;&lt;br /&gt;    }&lt;br /&gt;     }&lt;br /&gt;  }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Now the fun part finally arrived! Dave and I decided to write original music for the project so each one of us made loops. Now I can finally test the MIDI controller! When I set out to compose my loops it was a first for me. I usually write music in a linear and additive way because I work with software step sequencers, so by fragmenting a song in sections and in loops is something that I do not really do. It was very fun to write musical phrases that would sound good when combined with any of the other instruments. I decided to compose my song by writing themes and variations in just one key (C major). I laid out my song in different layers: bass, beats, arpeggios, ambient pads, lead melodies, and a heavily processed melody harp that would act as a sound texture. I wrote 4 different phrases for each layer and made them to be 6 seconds in duration. With Ableton's live syncing features we have so that each loop can be triggered but they only start at the beginning of the next phrase (in our case every 2 bars @ 160 bpm) so that the phrases are together in sync and in harmony. Needless to say I learned a lot by doing this song, and now I think I can write more music using this approach that then I can trigger live and improvise more on the fly.&lt;br /&gt;&lt;br /&gt;This project was very hard to do but I think it came out with a lot of the things that we wanted form the beginning. The deisgn is very beautiful, the lights work perfectly and add a lot, the sound reactive visuals look very good and the user experience is very gratifying. I learned a lot of programming and how to work in a group with something that I hold very close to my heart which is music. Is not very easy for me to work musically with other people since I have been playing with my current band mates for 7 years now and we have developed a musical understanding that is not easy to achieve. So for me to explain myself musically and explain how Ableton live works was a very difficult thing for me to do. Dave and I come from very different musical background and we perceive music composition and performance in very different ways, and to find a common ground between the two of us wasn't easy but we got there! I'm glad that even though the group had a lot of members, each one of us had a lot to do in the project and it shows. So, hopefully next year my band will get a few shows here in NYC and we can take out the MiXem!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/411157468520755607-1712827763736305628?l=pseq.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=9d5a6e76ab8a7cd1&amp;type=video%2Fmp4' length='0'/><link rel='replies' type='application/atom+xml' href='http://pseq.blogspot.com/feeds/1712827763736305628/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=411157468520755607&amp;postID=1712827763736305628' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/1712827763736305628'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/1712827763736305628'/><link rel='alternate' type='text/html' href='http://pseq.blogspot.com/2007/12/jose-olivares-notes-midicodeableton.html' title='Jose Olivares&apos; notes (MIDI/code/Ableton)'/><author><name>Jose Olivares</name><uri>http://www.blogger.com/profile/04515616948499092048</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-411157468520755607.post-3926485816590573060</id><published>2007-12-15T20:09:00.000-08:00</published><updated>2007-12-15T21:08:18.791-08:00</updated><title type='text'>Tymm Twillman - Notes on the Build</title><content type='html'>I have some notes &amp;amp; code on my &lt;a href="http://timothytwillman.com"&gt;personal blog&lt;/a&gt; but especially since Matt has put so much work into documentation here I'd like to add a bit to this collection too, and talk a little about the process and some of the things we ran into along the way.&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Matt, HeeJin and Jose had decided to continue their project from midterms, the block-based sequencer.  I decided to join the team, as it seemed like they had some really good ideas that mainly needed a bit of rounding out and engineering work, and I needed a really good idea to persue.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;A little later we found that Dave wasn't going to be working with the team he'd expected, and gladly welcomed him into the project.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;We quickly started coming up with features and ideas and new things to add.  There were several things that complicated issues; a number of us had pretty big deliverables in other classes, meeting times were difficult to work out with so many people, and backgrounds were diverse enough that it was hard to find common ground without leaving out things that were really important to team members.  When we agreed on implementation details, they were generally technically advanced and (as it turned out) would require greater degrees of coordination or had to be serialized.  We met week after week, trying to eliminate things which were superfluous or too difficult to implement and trying to find ideas which would bring the team together and allow us to focus on an actual build, and every week we had a new design which would end up knocking us back to... well, if not square one then square two.  We started with a design based on a grid of magnetic sensors which would allow both triggering and adjustment of parameters based on rotation of blocks (deemed not quite the right interface), then moved to RFID and modular scanning arrays (decided that we needed an immersive visual element) then moved to a circular setup with a display in the middle (the RFID element turned out to be too complicated, plus as it turns out the technology wasn't there to do many of the things we wanted to do reasonably cheaply).  We switched to iPod-style scroll wheels (required team to wait for scroll wheels to be done to develop most of interface, which it was decided was not a good idea), and finally ended up with the current proximity sensor design, as this made the system easy to prototype &amp;amp; test with normal switches, and the whole team could be working on different aspects of the design concurrently.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;While the roles were mostly not completely vertical, we mostly ended up in the following:&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Jose and Dave decided to tackle Midi code and the state machine, and work on sounds for the final piece.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;HeeJin took up the visual development, including designs for the pads and Processing code to give visual feedback to users &amp;amp; for performance.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Matt took on fabrication &amp;amp; testing.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;I took on building out the hardware &amp;amp; interface code.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;It ended up being an intense time for all of us.  I'll let the others speak for their parts, but I'll give a rundown of the hardware build.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;I had a board I'd put together years ago using qprox qt140 touch sensors, and I had a few random qt140's lying about.  When we decided to move away from the touch wheel interface, I decided to pull them out as a simple-to-interface alternative.  They have some configuration to set up, but for the most part they have 4 touch inputs &amp;amp; 4 digital outputs.  Easy.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;I brought the board to Matt &amp;amp; we played with it a bit with copper clad circles we were planning to use for touch sensors; while it seemed to work somewhat, the sensitivity was way too high.  We decided that using switches for prototyping would be the best for Jose and Dave until we had this all a bit more worked out.  I knew the range could be altered by adjusting capacitors on the board, and was able to test this to some degree with the initial board (enough to tell that we should be able to reach the range we wanted, but also enough to know that mounting was so important to the sensitivity that we shouldn't depend too much on results from the test board).&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;I spent a few hours &amp;amp; was able to create a PCB layout (using Eagle) that would work as a shield, holding two qt140's (with a careful groundplane layout) and support circuitry.  Since the case wasn't quite ready I kept this board to work on code, and began to work on the LED control circuitry.  TLC5490's had been talked about on some of the ITP lists before, so I decided to give some a shot (having played with, and been disappointed by, some Maxim i2c-based LED controllers in the past -- though that was likely largely due to my selection of LEDs at the time).  They turned out to be a total pain in the ass, though in the end I think worth it.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;I was getting low on time, so I decided to skip doing a full PCB layout for the 5940's (besides I had DIPs and for PCB layouts I generally prefer to do SMD).  I just used wirewrap wire, sockets and pin headers and soldered a board to plug into the top of the qt140 board.  It took a while, and soldering the LED's to little boards &amp;amp; attaching wires to plug into the 5940 board took another while.  &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;I ended up needing to steal pins from the Arduino analog port, since the touch controllers took 8 pins for switches + 2 pins for control; the serial connection took another 2, and with only 2 remaining digital pins I couldn't handle all the 5940 connections necessary.  So the TLC5940 board plugs into the Analog 0-4 (PORTC 0-4) pins, with two lines going to pins 10 and 11 (luckily I'd managed to leave two pins which can be timer-controlled available when doing the earlier layout).&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Code was the biggest pain.  There's an example on the Arduino site, but it didn't have quite the right interface and the clocking options weren't in the range I was looking for, so I ended up putting together my own code.  I used some code I'd had lying around for a while (evolved from my first AVR-based design, years ago!) to do a color fade test, and when I got my first color cycled output I knew it was all worthwhile.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The team pulled together for a big build night; lots of cutting (Matt did a great job at putting together a hatbox-cutting jig &amp;amp; getting our case trimmed down to size and cutting holes for the LED's to shine through), hot gluing, tweaking and testing.  I think we were all amazed, after everything we'd been through on building miXem, at just how great it looked in operation.  The code required only minor tweaking to get the LED bits working along with the Midi code (initially the two parts weren't integrated; the LED code did its own sensing of what buttons were pushed, etc... but this turned out to be a pretty lousy interface).  A few more changes of just a couple of lines brought us to the interface we showed in class.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Our biggest problem since the build has been occasional glitches; they seem to be due to the touch controllers getting confused (especially when items are placed on the table next to miXem, or when the case is opened &amp;amp; then re-closed).  For the ITP show, we opened it and cleaned up the wiring a bit, and hot glued the Arduino in place in the center.  This seems to have fixed most of these problems (though opening the case sometimes still causes it to become confused for a few moments).  I learned here to pay close attention with the prox sensors to how they scan; it's covered in a short section in the datasheet, but especially when using multiple prox sensors in conjunction -- it's important to synchronize the chips (qt140's have a sync line; sync lines from all of them should be connected together) and to make sure that multiple pads aren't being scanned at the same time in close proximity to each other (which is a wiring layout issue).  We were seeing (almost) rhythmic self-triggering in some of our initial tests where care wasn't given to wiring layout.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;In the end, I think the project turned out well.  I think most of the problems we ran into we were aware of and actively working to minimize (mainly with regards to trying to come to agreement on what &amp;amp; how to build, plus running into parts of the build that couldn't be parallelized), though I still hope to learn more about How to Quickly Develop Good Ideas With a Group.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/411157468520755607-3926485816590573060?l=pseq.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pseq.blogspot.com/feeds/3926485816590573060/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=411157468520755607&amp;postID=3926485816590573060' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/3926485816590573060'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/3926485816590573060'/><link rel='alternate' type='text/html' href='http://pseq.blogspot.com/2007/12/tymm-twillman-notes-on-build.html' title='Tymm Twillman - Notes on the Build'/><author><name>tymm</name><uri>http://www.blogger.com/profile/04618674728618621826</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-411157468520755607.post-6601965219319652474</id><published>2007-12-15T13:09:00.000-08:00</published><updated>2007-12-15T13:37:22.725-08:00</updated><title type='text'>Matt Young -- notes on QProx sensors and fabrication</title><content type='html'>Well, here's what looks to be my final entry on the MiXem blog. It's been an awesome experience to work with this team and create something that we're all totally proud of, not to mention something that actually looks good and works and is fun to play. That said, I'm writing this entry in a way that will be useful to come back to in a year for any reference purposes. I'm going to detail my role in developing the touch sensors and the fabrication of MiXem's housing, so if you're reading this and don't care to know about those things, please stop here. Otherwise, let's get started: &lt;br /&gt;&lt;br /&gt;For the sensors, we used Quantum Qprox QT140 proximity sensors attached to copper clad pc boarding. Creating the actual sensors was as easy as taking two-sided copper clad pc boarding and cutting it into 3” diameter discs. I also drilled holes in the middle (5/8”) to allow room for the LEDs that would live in the center. &lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_1feLB33OPtY/R2RId4Cd2HI/AAAAAAAAAEU/KLmXwbrRfNo/s1600-h/qprox2.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://3.bp.blogspot.com/_1feLB33OPtY/R2RId4Cd2HI/AAAAAAAAAEU/KLmXwbrRfNo/s200/qprox2.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5144316352460085362" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;However, it was attaching these sensors to the copper clad that proved a little tricky. The first time I tried this, I crudely laid a stripped wire on top of the copper clad and tried to solder it down. It took a good 20 minutes to get even a little bit of solder to stick to the copper and the wire, and even then the connection was not that trustworthy, not to mention ugly. Tymm then showed me that the right way to do this is to drill a tiny hole through each pc board, insert the end of a wire, solder that end, then file it down to be flush with the sensor. You get nice, tight connections this way with a mound of filed down solder connecting your wire to your sensors. He also showed me that a drop or two of resin (basically pine tar) on the copper will react when it's heated up by the iron to make the solder bond to the copper plate much better. And it smells good when you burn it as an added bonus. &lt;br /&gt;&lt;br /&gt;I should mention here that it's important not to file the solder down to the point where you can see the copper wire through the silver-colored solder. If this is the case, the wire can easily become dislodged and your connection will suffer. In general, it's a good idea so solder both sides of the wire to the copper (which worked because we have two sided copper clad) just to make sure the connection stays strong. Oh, and another thing, adding that resin to the copper can badly burn the copper connection, and if this happens your solder will simply refuse to attach. There's nothing you can do with burnt copper once it happens, so it's a good idea to merely heat up the resin rather than char it. &lt;br /&gt;&lt;br /&gt;Anyways, now that we had our sensors, it was time to test them out. Tymm had already done some work on a QProx chip and made a board with inputs/outputs and capacitors, so we used those to test. I wrote the following code to trigger LEDs to see how sensitive they were. &lt;br /&gt;&lt;br /&gt;/*&lt;br /&gt;*&lt;br /&gt;**** PCompFinalSwitchTest2serial****&lt;br /&gt;Basic switch test. Really just to see if we can get 4 switches to turn on LEDs. &lt;br /&gt;The idea is then replace the LEDs with .Ess files. Comments by Matt Young&lt;br /&gt;*&lt;br /&gt;11/17/07&lt;br /&gt;*&lt;br /&gt;*/&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;// intialize your LEDs on their appropriate Digital pins&lt;br /&gt;int ledPin7 = 7;&lt;br /&gt;int ledPin8 = 8;&lt;br /&gt;int ledPin12 = 12;&lt;br /&gt;int ledPin13 = 13;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;// same goes for the switches. Each switch according to its input on the Arduino&lt;br /&gt;int switchPin2 = 2;&lt;br /&gt;int switchPin3 = 3;&lt;br /&gt;int switchPin4 = 4;&lt;br /&gt;int switchPin5 = 5;&lt;br /&gt;&lt;br /&gt;// initialize the state of each switch. Start them in the OFF position. &lt;br /&gt;int switchState2 = 0;&lt;br /&gt;int switchState3 = 0;&lt;br /&gt;int switchState4 = 0;&lt;br /&gt;int switchState5 = 0;&lt;br /&gt;&lt;br /&gt;int inByte = 0;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;void setup()&lt;br /&gt;{&lt;br /&gt;  &lt;br /&gt;   Serial.begin(9600);&lt;br /&gt;  &lt;br /&gt;  //set each switch as an INPUT, using the pinMode function&lt;br /&gt;  pinMode (switchPin2, INPUT);&lt;br /&gt;  pinMode (switchPin3, INPUT);&lt;br /&gt;  pinMode (switchPin4, INPUT);&lt;br /&gt;  pinMode (switchPin5, INPUT);&lt;br /&gt;  &lt;br /&gt;  //set each LED as an OUTPUT, using the pinMode function&lt;br /&gt;  pinMode (ledPin7, OUTPUT);&lt;br /&gt;  pinMode (ledPin8, OUTPUT);&lt;br /&gt;  pinMode (ledPin12, OUTPUT);&lt;br /&gt;  pinMode (ledPin13, OUTPUT);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;void loop ()&lt;br /&gt;{&lt;br /&gt; // the state of your switch means READING the switch. Use digitalRead command&lt;br /&gt; switchState2 = digitalRead(switchPin2); &lt;br /&gt; switchState3 = digitalRead(switchPin3);&lt;br /&gt; switchState4 = digitalRead(switchPin4);&lt;br /&gt; switchState5 = digitalRead(switchPin5);&lt;br /&gt; &lt;br /&gt; &lt;br /&gt;&lt;br /&gt; &lt;br /&gt; // if your switch state reads “on“, then... &lt;br /&gt; if (switchState2 == 1)  {&lt;br /&gt;    digitalWrite(ledPin7, HIGH);  // turn on the LED&lt;br /&gt;    //Serial.print(switchState2, BYTE);&lt;br /&gt;  } else {  &lt;br /&gt;    digitalWrite(ledPin7, LOW); &lt;br /&gt;    //Serial.print(switchState2, BYTE);&lt;br /&gt;  }&lt;br /&gt;  &lt;br /&gt;  &lt;br /&gt;   if (switchState3 == 1)  {&lt;br /&gt;    digitalWrite(ledPin8, HIGH);  &lt;br /&gt;    //Serial.print(switchState3, BYTE);&lt;br /&gt;  } else {  &lt;br /&gt;    digitalWrite(ledPin8, LOW); &lt;br /&gt;    //Serial.print(switchState3, BYTE);&lt;br /&gt;  }&lt;br /&gt;  &lt;br /&gt;  &lt;br /&gt;   if (switchState4 == 1)  {&lt;br /&gt;    digitalWrite(ledPin12, HIGH);  &lt;br /&gt;    //Serial.print(switchState4, BYTE);&lt;br /&gt;  } else {  &lt;br /&gt;    digitalWrite(ledPin12, LOW); &lt;br /&gt;    //Serial.print(switchState4, BYTE);&lt;br /&gt;  }&lt;br /&gt;  &lt;br /&gt;  &lt;br /&gt;   if (switchState5 == 1)  {&lt;br /&gt;    digitalWrite(ledPin13, HIGH);  &lt;br /&gt;    //Serial.print(switchState5, BYTE);&lt;br /&gt;  } else {  &lt;br /&gt;    digitalWrite(ledPin13, LOW); &lt;br /&gt;    //Serial.print(switchState5, BYTE);&lt;br /&gt;  }&lt;br /&gt;  &lt;br /&gt;  &lt;br /&gt;   if (Serial.available() &gt; 0) {   // serial.available basically asks, “do we detect any incoming bytes?“. This says&lt;br /&gt;  // yes, if an incoming byte is detected, then execute these tasks:  &lt;br /&gt;    inByte = Serial.read();   // GET the incoming byte. &lt;br /&gt;  Serial.print(switchState2, BYTE);&lt;br /&gt;  Serial.print(switchState3, BYTE);&lt;br /&gt;  Serial.print(switchState4, BYTE);&lt;br /&gt;  Serial.print(switchState5, BYTE);&lt;br /&gt;  &lt;br /&gt; } &lt;br /&gt;}  // that's it! We're done&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;This particular version of the code you'll notice contains information for Serial output. At the time, we were working towards building our loops in Processing, but we later abandoned this in favor of a MIDI protocol. Either way, this code works for making LEDs turn on when they're triggered, so that's primarily what we were concerned with. &lt;br /&gt;&lt;br /&gt;One thing we noticed with the prox sensors is that they were super sensitive. Your hand could be, I dunno, 5 inches above the sensor and it would trigger. And because it was so sensitive, it acted in a buggy nature -- the LED was always blinking at irregular moments, due to either accidentally getting too close to it or from other electrical interference. Even buffering the sensor pads with acrylic and cardboard didn't affect their buggy-ness too much. To correctly temper their sensitivity, we changed capacitors from .1µF (microfarad) to .01µF. This made the sensors much less sensitive and buggy feeling, so we kept those for the final product. And just like that, our sensors were done. Here's a pic of the wiring... note the bright blue capacitors:&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_1feLB33OPtY/R2RI1YCd2II/AAAAAAAAAEc/ttlB3phz6vw/s1600-h/DSC00241.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://1.bp.blogspot.com/_1feLB33OPtY/R2RI1YCd2II/AAAAAAAAAEc/ttlB3phz6vw/s200/DSC00241.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5144316756187011202" /&gt;&lt;/a&gt; &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Fabrication of MiXem was another component of the project that I had a hand in. Building the housing was a little tricky, but I'm glad I got the opportunity to focus more on this part of the project. If I learned one thing with our midterm, it's to not discount the amount of time or energy that goes into actually building the prototype. Pretty things work better, right? &lt;br /&gt;&lt;br /&gt;Anyways, MiXem's housing is built using 3 materials: a cardboard hatbox, acrylic, and spray paint. The acrylic came from Canal plastics, and is just a 12”x12”x1/8” plexiglass sheet cut and laser etched (by the fantastic AMS) into 12 2.5” circles. That's as easy as dropping off and picking up from AMS, and the finished product looks fantastic. &lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_1feLB33OPtY/R2RGVoCd1_I/AAAAAAAAADU/Q53T3KCbLqU/s1600-h/acrylic1.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://2.bp.blogspot.com/_1feLB33OPtY/R2RGVoCd1_I/AAAAAAAAADU/Q53T3KCbLqU/s200/acrylic1.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5144314011702908914" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;MiXem's housing is nothing more than a very sexy leopard skin hatbox cut down to size. We chose a hatbox due mainly to it's size and cost, and not so much for the leopard print. Working with the hatbox was the tricky part though -- being a large and round object meant that it didn't neatly fit underneath any of the power tools we have in the shop, so any operating on it had to be done by hand. &lt;br /&gt;&lt;br /&gt;I started off needing to cut the box down to a manageable size. Knowing that we were intending to use the lid of the box as our touch surface for the acrylic, I aimed to cut the very bottom of the box down to a size that would allow enough room for MiXem's guts but still keep a low profile. I settled on 2” vertical. &lt;br /&gt;&lt;br /&gt;Measuring this neatly around a curved surface was not quick. Making a clean line at an even 2” from the bottom of the box is not easily achieved with a (flat) ruler and scratch marks, and I only had one hat box, so I knew I had to get this right on the first shot. My solution to this was to make a jig that would score the hatbox evenly around it's edge. Spending a little time in the woodshop, I made something that resembled a c-clamp out of wood that was precisely the height of the box, and then making a thin cut at 2” into the jig to insert a blade. Here's a few pictures:&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_1feLB33OPtY/R2RGqoCd2AI/AAAAAAAAADc/hXOzqzSNFeM/s1600-h/jig1.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://2.bp.blogspot.com/_1feLB33OPtY/R2RGqoCd2AI/AAAAAAAAADc/hXOzqzSNFeM/s200/jig1.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5144314372480161794" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_1feLB33OPtY/R2RGq4Cd2BI/AAAAAAAAADk/DrEerCZ1_hM/s1600-h/jig2.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://3.bp.blogspot.com/_1feLB33OPtY/R2RGq4Cd2BI/AAAAAAAAADk/DrEerCZ1_hM/s200/jig2.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5144314376775129106" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_1feLB33OPtY/R2RGq4Cd2CI/AAAAAAAAADs/rdJvi8HB0a8/s1600-h/DSC00253.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://3.bp.blogspot.com/_1feLB33OPtY/R2RGq4Cd2CI/AAAAAAAAADs/rdJvi8HB0a8/s200/DSC00253.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5144314376775129122" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Anyways, the extra work to making the jig proved VERY handy, as I was able to score a nice, tight line around the box. &lt;br /&gt;&lt;br /&gt;From here I had to cut the box, which was also a bit tricky. Like I said, because of the size of the hatbox, I couldn't exactly fit it underneath the head of the scroll saw. Besides, I had to be careful which tool to use, as any faster cuts could fray the edges of the cardboard and perhaps ruin it. My first instinct was to use a hacksaw, thinking that the fine teeth would cut a clean line. I experimented with a couple different ones I found in the lab, but none of them felt right. Then, by absolute chance, I stumbled across a regular serrated edge kitchen knife, and that turned out to work absolutely perfectly. It was small enough to give me good control but long enough to hold a straight line, and the edge was tight enough to not split the ends of the cardboard. Perfect. I made one pass around my line to score the box a bit deeper, and then made my cut. After this, I sanded the edge, put the lid on, and just like that we had our basic housing.  &lt;br /&gt;&lt;br /&gt;A quick word on this process though: one thing it taught me is the value of proper planning. Actually taking time to spec out the making of a tool like my scoring jig, and taking time to test how different tools react with your material like I did with my hacksaws, helped out tremendously in terms of how the final product looks. Word to the wise: build in plenty of time for this because it's worth it in the end. No doubt, it felt a little weird to take an hour or so to build a tool that I only used for 30 seconds, but it looked professional by the time I was done with it. &lt;br /&gt;&lt;br /&gt;That being said, I now had my box and my lid. From here, however, I had to find a way to cut clean holes into the lid to allow room for our LEDs. I started this process by tracing out the footprint of the lid on white paper and basically making a blueprint of where our touch pads were going to go. Finding the center of the blueprint with a square and some measurements, I measured the lip of each touchpad to be 5” from the center after testing a few other distances. 5” felt about right for the instrument - Dave and I mimicked playing the instrument on the blueprint, and we both decided that 5” was the way to go. I then measured out at 60,120,180,240,300, and 360 degrees and scored where I'd drill my holes for the LEDs. &lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_1feLB33OPtY/R2RHB4Cd2DI/AAAAAAAAAD0/7ErjgbEOrwM/s1600-h/blueprint2.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://3.bp.blogspot.com/_1feLB33OPtY/R2RHB4Cd2DI/AAAAAAAAAD0/7ErjgbEOrwM/s200/blueprint2.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5144314771912120370" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Drilling the holes for the LEDs proved to be problematic though. Using some scrap hatbox from earlier, I tested the drill press with the 5/8” bit and it simply tore it up. The cardboard frayed like crazy, so I knew drilling wouldn't work. I even tried  taping both sides with painters tape to see if that would help suppress the fraying (on a great suggestion by Christian Cerrito, by the way), but that didn't help much. This cardboard was proving to be very delicate, so I had to find some other way. I'm definitely going to keep this taping trick in mind for the future though; even though cardboard isn't the right material for it, tape would be a good solution to this problem in many cases. &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Eventually, I decided on, again, making a jig to help me out. This time, I simply drilled a hole into a piece of scrap acrylic 5/8” wide and used that as a template with which I could trace the 6 LED ports on the lid. From there, I cut each hole with an exacto knife by hand. This was an incredibly tedious process, but none of the cardboard got frayed. I also filed a couple of the rough edges down with the circular file, just to make it look a little prettier. The end result looked great.&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_1feLB33OPtY/R2RHUICd2EI/AAAAAAAAAD8/3_KF6kblrvM/s1600-h/holes.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://4.bp.blogspot.com/_1feLB33OPtY/R2RHUICd2EI/AAAAAAAAAD8/3_KF6kblrvM/s200/holes.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5144315085444732994" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Once I had my holes, it was just a matter of painting and hooking the sensors up inside. For paint, I went with a white spray enamel that I picked up from Kmart for $1.79 per canister. The enamel is a little more tricky to work with, but it does leave a nice glossy finish on the outside, sort of like an iPod. Sort of. I took this home to paint outside and, after letting this dry for about 5 or 6 hours, came back and we were ready to attach the sensors. &lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_1feLB33OPtY/R2RIBYCd2FI/AAAAAAAAAEE/HkEccUn_k00/s1600-h/PCOMPmatt.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://1.bp.blogspot.com/_1feLB33OPtY/R2RIBYCd2FI/AAAAAAAAAEE/HkEccUn_k00/s200/PCOMPmatt.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5144315862833813586" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_1feLB33OPtY/R2RIBoCd2GI/AAAAAAAAAEM/T7MxMBV_WPo/s1600-h/MiXem2.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://2.bp.blogspot.com/_1feLB33OPtY/R2RIBoCd2GI/AAAAAAAAAEM/T7MxMBV_WPo/s200/MiXem2.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5144315867128780898" /&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/411157468520755607-6601965219319652474?l=pseq.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pseq.blogspot.com/feeds/6601965219319652474/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=411157468520755607&amp;postID=6601965219319652474' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/6601965219319652474'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/6601965219319652474'/><link rel='alternate' type='text/html' href='http://pseq.blogspot.com/2007/12/matt-young-notes-on-qprox-sensors-and.html' title='Matt Young -- notes on QProx sensors and fabrication'/><author><name>myg3000</name><uri>http://www.blogger.com/profile/02275784179300760298</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_1feLB33OPtY/R2RId4Cd2HI/AAAAAAAAAEU/KLmXwbrRfNo/s72-c/qprox2.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-411157468520755607.post-3443682602470944019</id><published>2007-12-12T12:25:00.000-08:00</published><updated>2007-12-12T14:51:59.329-08:00</updated><title type='text'></title><content type='html'>&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-ef09350ceedc8f2a" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v18.nonxt5.googlevideo.com/videoplayback?id%3Def09350ceedc8f2a%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1329907329%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D6FBC08362A9BB450A7B0E5D4D24F10FD11119AAE.2F3E348365F94AD3116F00E00D851341C4EF030%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3Def09350ceedc8f2a%26offsetms%3D5000%26itag%3Dw160%26sigh%3DPaOCVLrGukTger2RH5ndVONuBBg&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v18.nonxt5.googlevideo.com/videoplayback?id%3Def09350ceedc8f2a%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1329907329%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D6FBC08362A9BB450A7B0E5D4D24F10FD11119AAE.2F3E348365F94AD3116F00E00D851341C4EF030%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3Def09350ceedc8f2a%26offsetms%3D5000%26itag%3Dw160%26sigh%3DPaOCVLrGukTger2RH5ndVONuBBg&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/411157468520755607-3443682602470944019?l=pseq.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=ef09350ceedc8f2a&amp;type=video%2Fmp4' length='0'/><link rel='replies' type='application/atom+xml' href='http://pseq.blogspot.com/feeds/3443682602470944019/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=411157468520755607&amp;postID=3443682602470944019' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/3443682602470944019'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/3443682602470944019'/><link rel='alternate' type='text/html' href='http://pseq.blogspot.com/2007/12/blog-post.html' title=''/><author><name>myg3000</name><uri>http://www.blogger.com/profile/02275784179300760298</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-411157468520755607.post-8004531600400298723</id><published>2007-12-11T16:46:00.000-08:00</published><updated>2007-12-11T16:47:59.852-08:00</updated><title type='text'>Real life photos of the MiXem!</title><content type='html'>&lt;a href="http://3.bp.blogspot.com/_jQmgHOJF8Q4/R18vkfPUGFI/AAAAAAAAAAM/xz4yl4Hauh4/s1600-h/MiXem320.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://3.bp.blogspot.com/_jQmgHOJF8Q4/R18vkfPUGFI/AAAAAAAAAAM/xz4yl4Hauh4/s320/MiXem320.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5142881603387922514" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;The rumors were true.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/411157468520755607-8004531600400298723?l=pseq.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pseq.blogspot.com/feeds/8004531600400298723/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=411157468520755607&amp;postID=8004531600400298723' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/8004531600400298723'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/8004531600400298723'/><link rel='alternate' type='text/html' href='http://pseq.blogspot.com/2007/12/real-life-photos-of-mixem.html' title='Real life photos of the MiXem!'/><author><name>Dave</name><uri>http://www.blogger.com/profile/07355449910239957507</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_jQmgHOJF8Q4/R18vkfPUGFI/AAAAAAAAAAM/xz4yl4Hauh4/s72-c/MiXem320.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-411157468520755607.post-2300669642262308515</id><published>2007-12-02T18:15:00.000-08:00</published><updated>2007-12-02T19:53:57.881-08:00</updated><title type='text'>Design</title><content type='html'>This is Heejin's design for the acrylic switches. The idea here was to come up with something that we could send off to the Advanced Media Studio to be laser etched. We're pretty happy with the results so far. Check it: &lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_1feLB33OPtY/R1N9iBzRhfI/AAAAAAAAADE/J1TH1uCXj5A/s1600-R/design005.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://3.bp.blogspot.com/_1feLB33OPtY/R1N9iBzRhfI/AAAAAAAAADE/fobY81OonS8/s200/design005.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5139589623312385522" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_1feLB33OPtY/R1N9uhzRhgI/AAAAAAAAADM/BK_7te7XYqc/s1600-R/acrylic1.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://1.bp.blogspot.com/_1feLB33OPtY/R1N9uhzRhgI/AAAAAAAAADM/tWWTWuSkLho/s200/acrylic1.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5139589838060750338" /&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/411157468520755607-2300669642262308515?l=pseq.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pseq.blogspot.com/feeds/2300669642262308515/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=411157468520755607&amp;postID=2300669642262308515' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/2300669642262308515'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/2300669642262308515'/><link rel='alternate' type='text/html' href='http://pseq.blogspot.com/2007/12/design.html' title='Design'/><author><name>myg3000</name><uri>http://www.blogger.com/profile/02275784179300760298</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_1feLB33OPtY/R1N9iBzRhfI/AAAAAAAAADE/fobY81OonS8/s72-c/design005.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-411157468520755607.post-411159025904992313</id><published>2007-12-02T11:42:00.001-08:00</published><updated>2007-12-02T12:35:47.145-08:00</updated><title type='text'>Sensors test</title><content type='html'>Well, we got the prox sensors working. We've decided to switch to something more like straight-up switches for the functionality of the sequencer. Originally, we wanted to do little iPod-scroll-wheel-like sensors, but the functionality of this would have been very complicated to both code and to use, so we dropped that idea in favor of something a bit more simple. Simple is good. &lt;br /&gt;&lt;br /&gt;Anyways, below you have the video of how this worked. I wrote a very simple code to trigger different colored LEDs. The green and ultrabright blue LEDs are hooked up through a .1 uF capacitor that makes them especially sensitive. The yellow LED is wired to a .01 uF capacitor that makes for a bit better functionality I think: the switches don't accidentally trigger, which will be important as the circular shape of the sequencer will require the user to reach across certain switches to access others. So, lower capacitance means less buggy feeling. &lt;br /&gt;&lt;br /&gt;Here's the video. Note the yellow LED and how it works consistently, and how the blue and green trigger erratically. Simple LED code below. &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-8c0ae4728a8a8d9f" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v2.nonxt7.googlevideo.com/videoplayback?id%3D8c0ae4728a8a8d9f%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1329907329%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D6BD3ADC7AAA8EC8556AB702F20A2F0F8E8A1BB2D.1BB476CA52875ABFDB90C8EAE0AFC7711BFEB2E6%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D8c0ae4728a8a8d9f%26offsetms%3D5000%26itag%3Dw160%26sigh%3Dpnd6Ewy6vy1Sk1hX0xjVvzMoVpM&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v2.nonxt7.googlevideo.com/videoplayback?id%3D8c0ae4728a8a8d9f%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1329907329%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D6BD3ADC7AAA8EC8556AB702F20A2F0F8E8A1BB2D.1BB476CA52875ABFDB90C8EAE0AFC7711BFEB2E6%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D8c0ae4728a8a8d9f%26offsetms%3D5000%26itag%3Dw160%26sigh%3Dpnd6Ewy6vy1Sk1hX0xjVvzMoVpM&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;int ledPin1 = 8;&lt;br /&gt;int ledPin2 = 12;&lt;br /&gt;int ledPin3 = 13;&lt;br /&gt;&lt;br /&gt;int switchPin4 = 4;&lt;br /&gt;int switchPin3 = 3; &lt;br /&gt;int switchPin2 = 2;&lt;br /&gt;&lt;br /&gt;int switchState2 = 0;&lt;br /&gt;int switchState3 = 0;&lt;br /&gt;int switchState4 = 0;&lt;br /&gt;&lt;br /&gt;void setup()  {&lt;br /&gt;  pinMode (switchPin2, INPUT);&lt;br /&gt;  pinMode (switchPin3, INPUT);&lt;br /&gt;  pinMode (switchPin4, INPUT);&lt;br /&gt;  &lt;br /&gt;  pinMode (ledPin1, OUTPUT);&lt;br /&gt;  pinMode (ledPin2, OUTPUT);&lt;br /&gt;  pinMode (ledPin3, OUTPUT);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;void loop()  {&lt;br /&gt;  switchState2 = digitalRead(switchPin2);&lt;br /&gt;  switchState3 = digitalRead(switchPin3);&lt;br /&gt;  switchState4 = digitalRead(switchPin4);&lt;br /&gt;  &lt;br /&gt;  if (switchState2 == 1)  {&lt;br /&gt;    digitalWrite(ledPin1, HIGH);&lt;br /&gt;  } else {&lt;br /&gt;    digitalWrite(ledPin1, LOW);&lt;br /&gt;  }&lt;br /&gt;  &lt;br /&gt;  if (switchState3 == 1)  {&lt;br /&gt;    digitalWrite(ledPin2, HIGH);&lt;br /&gt;  } else {&lt;br /&gt;    digitalWrite(ledPin2, LOW);&lt;br /&gt;  }&lt;br /&gt;  &lt;br /&gt;  if (switchState4 == 1)  {&lt;br /&gt;    digitalWrite(ledPin3, HIGH);&lt;br /&gt;  } else {&lt;br /&gt;    digitalWrite(ledPin3, LOW);&lt;br /&gt;  }&lt;br /&gt;}&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/411157468520755607-411159025904992313?l=pseq.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=8c0ae4728a8a8d9f&amp;type=video%2Fmp4' length='0'/><link rel='replies' type='application/atom+xml' href='http://pseq.blogspot.com/feeds/411159025904992313/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=411157468520755607&amp;postID=411159025904992313' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/411159025904992313'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/411159025904992313'/><link rel='alternate' type='text/html' href='http://pseq.blogspot.com/2007/12/sensors-test.html' title='Sensors test'/><author><name>myg3000</name><uri>http://www.blogger.com/profile/02275784179300760298</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-411157468520755607.post-1175630104053382533</id><published>2007-11-21T12:14:00.000-08:00</published><updated>2007-11-21T12:26:10.413-08:00</updated><title type='text'>even better MIDI</title><content type='html'>sweet. 3 potentiometers, tied to two types of pitch and frequency -- pay attention to the two circular dials at the bottom and the graph thing. all done in Ableton Live. &lt;br /&gt;&lt;br /&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-474a7a8173d7bdcf" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v21.nonxt8.googlevideo.com/videoplayback?id%3D474a7a8173d7bdcf%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1329907329%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D1DCF031EA0A8EECD5F2F4DE1E5567E6F9A708773.2BE0D9BB8005E464523126AD641831B4B49C6791%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D474a7a8173d7bdcf%26offsetms%3D5000%26itag%3Dw160%26sigh%3D3Ef0dS27H4FK04tP57TNKPs0JDg&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v21.nonxt8.googlevideo.com/videoplayback?id%3D474a7a8173d7bdcf%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1329907329%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D1DCF031EA0A8EECD5F2F4DE1E5567E6F9A708773.2BE0D9BB8005E464523126AD641831B4B49C6791%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D474a7a8173d7bdcf%26offsetms%3D5000%26itag%3Dw160%26sigh%3D3Ef0dS27H4FK04tP57TNKPs0JDg&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;code to come.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/411157468520755607-1175630104053382533?l=pseq.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=474a7a8173d7bdcf&amp;type=video%2Fmp4' length='0'/><link rel='replies' type='application/atom+xml' href='http://pseq.blogspot.com/feeds/1175630104053382533/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=411157468520755607&amp;postID=1175630104053382533' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/1175630104053382533'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/1175630104053382533'/><link rel='alternate' type='text/html' href='http://pseq.blogspot.com/2007/11/even-better-midi.html' title='even better MIDI'/><author><name>myg3000</name><uri>http://www.blogger.com/profile/02275784179300760298</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-411157468520755607.post-3218733462908846773</id><published>2007-11-20T10:26:00.000-08:00</published><updated>2007-11-20T11:37:30.532-08:00</updated><title type='text'>MIDI anyone?</title><content type='html'>&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_1feLB33OPtY/R0MnqER6g9I/AAAAAAAAACo/Ogjy0azKRuU/s1600-h/borat1.jpg"&gt;&lt;img style="margin: 0pt 10px 10px 0pt; float: left; cursor: pointer;" src="http://4.bp.blogspot.com/_1feLB33OPtY/R0MnqER6g9I/AAAAAAAAACo/Ogjy0azKRuU/s200/borat1.jpg" alt="" id="BLOGGER_PHOTO_ID_5134991603789366226" border="0"&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Wait. Rather than muck up our coding in Processing, why not generate sound through MIDI? It makes better sound AND we can play it through Ableton Live AND it was invented in Kazakhstan in 1981. I think. And it means no gross coding in Processing. &lt;br /&gt;&lt;br /&gt;Hi 5!&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Actual pics &amp;amp; vid of Jose demonstrating: &lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_1feLB33OPtY/R0MooER6g-I/AAAAAAAAACw/spkg79RD9sM/s1600-h/MIDIbox.jpg"&gt;&lt;img style="margin: 0pt 10px 10px 0pt; float: left; cursor: pointer;" src="http://4.bp.blogspot.com/_1feLB33OPtY/R0MooER6g-I/AAAAAAAAACw/spkg79RD9sM/s200/MIDIbox.jpg" alt="" id="BLOGGER_PHOTO_ID_5134992668941255650" border="0"&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_1feLB33OPtY/R0MooUR6g_I/AAAAAAAAAC4/vVF7dOhSEvc/s1600-h/MIDIwiring.jpg"&gt;&lt;img style="margin: 0pt 10px 10px 0pt; float: left; cursor: pointer;" src="http://1.bp.blogspot.com/_1feLB33OPtY/R0MooUR6g_I/AAAAAAAAAC4/vVF7dOhSEvc/s200/MIDIwiring.jpg" alt="" id="BLOGGER_PHOTO_ID_5134992673236222962" border="0"&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-868be5cdf8894992" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v12.nonxt2.googlevideo.com/videoplayback?id%3D868be5cdf8894992%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1329907329%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D5F80B55E5A52F87A633B8152C54C4D207801E096.44CBF9236791366125C8A30A68B4BC07BB32946D%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D868be5cdf8894992%26offsetms%3D5000%26itag%3Dw160%26sigh%3DwF0-pkmJMf3936KXoq1uX3vqLUc&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v12.nonxt2.googlevideo.com/videoplayback?id%3D868be5cdf8894992%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1329907329%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D5F80B55E5A52F87A633B8152C54C4D207801E096.44CBF9236791366125C8A30A68B4BC07BB32946D%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D868be5cdf8894992%26offsetms%3D5000%26itag%3Dw160%26sigh%3DwF0-pkmJMf3936KXoq1uX3vqLUc&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/411157468520755607-3218733462908846773?l=pseq.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=868be5cdf8894992&amp;type=video%2Fmp4' length='0'/><link rel='replies' type='application/atom+xml' href='http://pseq.blogspot.com/feeds/3218733462908846773/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=411157468520755607&amp;postID=3218733462908846773' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/3218733462908846773'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/3218733462908846773'/><link rel='alternate' type='text/html' href='http://pseq.blogspot.com/2007/11/midi-anyone.html' title='MIDI anyone?'/><author><name>myg3000</name><uri>http://www.blogger.com/profile/02275784179300760298</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_1feLB33OPtY/R0MnqER6g9I/AAAAAAAAACo/Ogjy0azKRuU/s72-c/borat1.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-411157468520755607.post-6544275238345167953</id><published>2007-11-19T18:36:00.001-08:00</published><updated>2007-11-19T19:28:16.547-08:00</updated><title type='text'>some basic coding</title><content type='html'>here comes the boring part of the project: the ugly birth of arduino/processing code. Basically, we started off just trying to get some switches to play sound. Seemed easy enough. Below is the video of how we're doing so far, followed by the code for Arduino/Processing for reference sake. &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;}&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-b9866046336d15e2" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v17.nonxt2.googlevideo.com/videoplayback?id%3Db9866046336d15e2%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1329907329%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D633E3818238626C379C4F9A80EA53923BC2E0692.3378406DFB1AF3205719AF79FE3D5178BC9F76FD%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3Db9866046336d15e2%26offsetms%3D5000%26itag%3Dw160%26sigh%3DJ8DNdZ5Si7jy2zD3txf38sTYHmg&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v17.nonxt2.googlevideo.com/videoplayback?id%3Db9866046336d15e2%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1329907329%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D633E3818238626C379C4F9A80EA53923BC2E0692.3378406DFB1AF3205719AF79FE3D5178BC9F76FD%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3Db9866046336d15e2%26offsetms%3D5000%26itag%3Dw160%26sigh%3DJ8DNdZ5Si7jy2zD3txf38sTYHmg&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;ARDUINO: &lt;br /&gt;&lt;br /&gt;/*&lt;br /&gt;*&lt;br /&gt;**** PCompFinalSwitchTest2serial****&lt;br /&gt;Basic switch test. Really just to see if we can get 4 switches to turn on LEDs. &lt;br /&gt;The idea is then replace the LEDs with .Ess files, then replace the switches with &lt;br /&gt;analog resistors. Comments by Matt Young&lt;br /&gt;*&lt;br /&gt;11/17/07&lt;br /&gt;*&lt;br /&gt;*/&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;// intialize your LEDs on their appropriate Digital pins&lt;br /&gt;int ledPin7 = 7;&lt;br /&gt;int ledPin8 = 8;&lt;br /&gt;int ledPin12 = 12;&lt;br /&gt;int ledPin13 = 13;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;// same goes for the switches. Each switch according to its input on the Arduino&lt;br /&gt;int switchPin2 = 2;&lt;br /&gt;int switchPin3 = 3;&lt;br /&gt;int switchPin4 = 4;&lt;br /&gt;int switchPin5 = 5;&lt;br /&gt;&lt;br /&gt;// initialize the state of each switch. Start them in the OFF position. &lt;br /&gt;int switchState2 = 0;&lt;br /&gt;int switchState3 = 0;&lt;br /&gt;int switchState4 = 0;&lt;br /&gt;int switchState5 = 0;&lt;br /&gt;&lt;br /&gt;int inByte = 0;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;void setup()&lt;br /&gt;{&lt;br /&gt;  &lt;br /&gt;   Serial.begin(9600);&lt;br /&gt;  &lt;br /&gt;  //set each switch as an INPUT, using the pinMode function&lt;br /&gt;  pinMode (switchPin2, INPUT);&lt;br /&gt;  pinMode (switchPin3, INPUT);&lt;br /&gt;  pinMode (switchPin4, INPUT);&lt;br /&gt;  pinMode (switchPin5, INPUT);&lt;br /&gt;  &lt;br /&gt;  //set each LED as an OUTPUT, using the pinMode function&lt;br /&gt;  pinMode (ledPin7, OUTPUT);&lt;br /&gt;  pinMode (ledPin8, OUTPUT);&lt;br /&gt;  pinMode (ledPin12, OUTPUT);&lt;br /&gt;  pinMode (ledPin13, OUTPUT);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;void loop ()&lt;br /&gt;{&lt;br /&gt; // the state of your switch means READING the switch. Use digitalRead command&lt;br /&gt; switchState2 = digitalRead(switchPin2); &lt;br /&gt; switchState3 = digitalRead(switchPin3);&lt;br /&gt; switchState4 = digitalRead(switchPin4);&lt;br /&gt; switchState5 = digitalRead(switchPin5);&lt;br /&gt; &lt;br /&gt; &lt;br /&gt;&lt;br /&gt; &lt;br /&gt; // if your switch state reads "on", then... &lt;br /&gt; if (switchState2 == 1)  {&lt;br /&gt;    digitalWrite(ledPin7, HIGH);  // turn on the LED&lt;br /&gt;  } else {  &lt;br /&gt;    digitalWrite(ledPin7, LOW); &lt;br /&gt;  }&lt;br /&gt;  &lt;br /&gt;  &lt;br /&gt;   if (switchState3 == 1)  {&lt;br /&gt;    digitalWrite(ledPin8, HIGH);  &lt;br /&gt;  } else {  &lt;br /&gt;    digitalWrite(ledPin8, LOW); &lt;br /&gt;  }&lt;br /&gt;  &lt;br /&gt;  &lt;br /&gt;   if (switchState4 == 1)  {&lt;br /&gt;    digitalWrite(ledPin12, HIGH);  &lt;br /&gt;  } else {  &lt;br /&gt;    digitalWrite(ledPin12, LOW); &lt;br /&gt;  }&lt;br /&gt;  &lt;br /&gt;  &lt;br /&gt;   if (switchState5 == 1)  {&lt;br /&gt;    digitalWrite(ledPin13, HIGH);  &lt;br /&gt;  } else {  &lt;br /&gt;    digitalWrite(ledPin13, LOW); &lt;br /&gt;  }&lt;br /&gt;  &lt;br /&gt;  &lt;br /&gt;   if (Serial.available() &amp;gt; 0) {   // serial.available basically asks, "do we detect any incoming bytes?". This says&lt;br /&gt;  // yes, if an incoming byte is detected, then execute these tasks:  &lt;br /&gt;    inByte = Serial.read();   // GET the incoming byte. &lt;br /&gt;  Serial.print(switchState2, BYTE);&lt;br /&gt;  Serial.print(switchState3, BYTE);&lt;br /&gt;  Serial.print(switchState4, BYTE);&lt;br /&gt;  Serial.print(switchState5, BYTE);&lt;br /&gt;  &lt;br /&gt; } &lt;br /&gt;}  // that's it! We're done&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;PROCESSING:&lt;br /&gt;&lt;br /&gt;import processing.serial.*;&lt;br /&gt;&lt;br /&gt;Serial myPort; &lt;br /&gt;int[] switchArray = new int [4];&lt;br /&gt;int serialCount = 0;&lt;br /&gt;&lt;br /&gt;boolean firstContact = false;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;import krister.Ess.*;&lt;br /&gt;&lt;br /&gt;AudioChannel mySample1;&lt;br /&gt;AudioChannel mySample2;&lt;br /&gt;AudioChannel mySample3;&lt;br /&gt;AudioChannel mySample4;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;void setup()&lt;br /&gt;{&lt;br /&gt;   //intitializing serial ports&lt;br /&gt;  println(Serial.list());              // start off with printing the available serial ports&lt;br /&gt;  myPort = new Serial (this,Serial.list()[0],9600);        // selecting this serial port, at #0&lt;br /&gt; &lt;br /&gt;   println("hello");&lt;br /&gt;  //println(myPort.available());&lt;br /&gt;  myPort.write(65);&lt;br /&gt;  &lt;br /&gt;  &lt;br /&gt;  //start the Ess library&lt;br /&gt;  Ess.start(this);&lt;br /&gt;  &lt;br /&gt;  &lt;br /&gt;  mySample1=new AudioChannel();              //set up audio channel &lt;br /&gt;  mySample1.loadSound("bass.aif");          // load the .wav file in it. Have your assets in a data folder&lt;br /&gt;&lt;br /&gt;  mySample2=new AudioChannel();&lt;br /&gt;  mySample2.loadSound("adore.wav");&lt;br /&gt;&lt;br /&gt;  mySample3=new AudioChannel(); &lt;br /&gt;  mySample3.loadSound("guitar.aif"); &lt;br /&gt;  &lt;br /&gt;  mySample4=new AudioChannel();&lt;br /&gt;  mySample4.loadSound("synth.aif");&lt;br /&gt; &lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;void draw()&lt;br /&gt;{&lt;br /&gt;  if (firstContact == false)   {&lt;br /&gt;   delay(300);&lt;br /&gt;   myPort.write(65);&lt;br /&gt;   println("I just sent some more data");&lt;br /&gt;}&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;public void stop() {  // note how "public void stop" is on it's own, outside of "draw" and "serialEvent"&lt;br /&gt;    Ess.stop();&lt;br /&gt;    super.stop();&lt;br /&gt;  }&lt;br /&gt;  &lt;br /&gt;  &lt;br /&gt;  &lt;br /&gt;void serialEvent(Serial myPort)  {&lt;br /&gt;  &lt;br /&gt;  &lt;br /&gt;  if (firstContact == false)  {&lt;br /&gt;    firstContact = true;&lt;br /&gt;    println("Data Received yo");&lt;br /&gt;  }&lt;br /&gt;&lt;br /&gt;  switchArray[serialCount] = myPort.read();       // read what you get from your serial port. Define that as your sensor array&lt;br /&gt;  serialCount++;                               // scroll through your sensor count&lt;br /&gt;  &lt;br /&gt; int val0 = switchArray[0];            // equate your values to particular spots in the array&lt;br /&gt; int val1 = switchArray[1];&lt;br /&gt; int val2 = switchArray[2];&lt;br /&gt; int val3 = switchArray[3];&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;  if (serialCount &amp;gt; 3)  {                      // if we detect more than two bytes being sent, execute the below code. &lt;br /&gt;  println(myPort.available());&lt;br /&gt;  &lt;br /&gt;  &lt;br /&gt;  if (val0 &amp;gt; 0)  {          // if we get anything from switch 1, play sample 1. &lt;br /&gt;     mySample1.play(1);&lt;br /&gt;  } &lt;br /&gt;  &lt;br /&gt;  if (val1 &amp;gt; 0)  {&lt;br /&gt;    mySample2.play(1);&lt;br /&gt;  }&lt;br /&gt;  &lt;br /&gt;  if (val2 &amp;gt; 0)  {&lt;br /&gt;    mySample3.play(1);&lt;br /&gt;  }&lt;br /&gt;  &lt;br /&gt;  if (val3 &amp;gt; 0)  {&lt;br /&gt;    mySample4.play(1);&lt;br /&gt;  }&lt;br /&gt;  &lt;br /&gt;  &lt;br /&gt;  &lt;br /&gt;  println(val0 + "\t" + val1 + "\t" + val2 + "\t" + val3);    // let's just print our data for right now. &lt;br /&gt;    myPort.write(65);&lt;br /&gt;    serialCount = 0;                           // ...and then reset the serial counter back to 0, or otherwise it jams up. &lt;br /&gt;  }&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/411157468520755607-6544275238345167953?l=pseq.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=b9866046336d15e2&amp;type=video%2Fmp4' length='0'/><link rel='replies' type='application/atom+xml' href='http://pseq.blogspot.com/feeds/6544275238345167953/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=411157468520755607&amp;postID=6544275238345167953' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/6544275238345167953'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/6544275238345167953'/><link rel='alternate' type='text/html' href='http://pseq.blogspot.com/2007/11/some-basic-coding.html' title='some basic coding'/><author><name>myg3000</name><uri>http://www.blogger.com/profile/02275784179300760298</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-411157468520755607.post-3055434435848302796</id><published>2007-11-17T16:30:00.000-08:00</published><updated>2007-11-17T17:22:20.574-08:00</updated><title type='text'>new stuff</title><content type='html'>ok well, physical sequencer may or may not be the best name for this project at this point. After a few meetings and tons of ideas floating around, we've arrived at this: &lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_1feLB33OPtY/Rz-SWkR6g8I/AAAAAAAAACg/Z2jeEiEaYUY/s1600-h/well2.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://2.bp.blogspot.com/_1feLB33OPtY/Rz-SWkR6g8I/AAAAAAAAACg/Z2jeEiEaYUY/s200/well2.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5133983016619246530" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Again, Heejin's interpretation is awesome. The idea is to assign each circle an instrument, but once an instrument is selected (with your hand), the other circles will be "soft" buttons that control different effects. &lt;br /&gt;&lt;br /&gt;Where are the cubes you ask? Good question. After chewing this over for a few hours, we decided that the appropriate appendage to use is the old-fashioned human hand rather than a new-fangled acrylic blinking cube. This will be awesome though -- as you touch one pad, it will animate with a tri-colored LED embedded underneath and respond with the assigned instrument. Then, using ______ sensors [insert link], you'll be able to control the effects. &lt;br /&gt;&lt;br /&gt;We're using etched acrylic for each pad, tri-colored LEDs underneath, and ______ sensors to perform the effects. These will be located underneath each 3" pad. In the middle is an LCD monitor that will animate further. &lt;br /&gt;&lt;br /&gt;More pics/ideas to come.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/411157468520755607-3055434435848302796?l=pseq.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pseq.blogspot.com/feeds/3055434435848302796/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=411157468520755607&amp;postID=3055434435848302796' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/3055434435848302796'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/3055434435848302796'/><link rel='alternate' type='text/html' href='http://pseq.blogspot.com/2007/11/new-stuff.html' title='new stuff'/><author><name>myg3000</name><uri>http://www.blogger.com/profile/02275784179300760298</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_1feLB33OPtY/Rz-SWkR6g8I/AAAAAAAAACg/Z2jeEiEaYUY/s72-c/well2.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-411157468520755607.post-1242802077644559820</id><published>2007-11-05T14:15:00.001-08:00</published><updated>2007-11-05T15:08:51.106-08:00</updated><title type='text'>sound cubes, redux</title><content type='html'>Hi all -- and welcome to Round II of Heejin, Jose, and Matt's sound cubes project for their Physical Computing midterm. I'm Matt, and from this point forward I'll post in first-person only. I promise. For Round I notes on this project, check out our &lt;a href="http://inkivory.blogspot.com/"&gt;midterm blog&lt;/a&gt;, which is helplessly out of date. &lt;br /&gt;&lt;br /&gt;If you like movies, and I know you do, check this out: &lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-ebc14eec7a923b18" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v13.nonxt5.googlevideo.com/videoplayback?id%3Debc14eec7a923b18%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1329907329%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D7B7FF6DAB5EDBDF5C00357550F67B4322657B55B.5F0CB6B05C16F2B62DD6C2EB4F4F298CF0A8A975%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3Debc14eec7a923b18%26offsetms%3D5000%26itag%3Dw160%26sigh%3Ds_bQ1i5fLsP9GiTpl5D557UhuTA&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v13.nonxt5.googlevideo.com/videoplayback?id%3Debc14eec7a923b18%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1329907329%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D7B7FF6DAB5EDBDF5C00357550F67B4322657B55B.5F0CB6B05C16F2B62DD6C2EB4F4F298CF0A8A975%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3Debc14eec7a923b18%26offsetms%3D5000%26itag%3Dw160%26sigh%3Ds_bQ1i5fLsP9GiTpl5D557UhuTA&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;br /&gt;&lt;br /&gt;Anyways, big changes this time around. First and foremost, we're welcoming a fourth member into our group, Tymm (picture forthcoming). Tymm's got some great ideas, and when we all met today we decided on blowing out this project. Changes to come: &lt;br /&gt;&lt;br /&gt;1) We're going to focus on making this a sequencer rather than an instrument. This is important, because it will allow us greater flexibility in incorporating both audio and video. &lt;br /&gt;&lt;br /&gt;2) Yes, we're going to incorporate video, or some sort of visual interface (most likely Processing sketches for now, which Heejin is working on). &lt;br /&gt;&lt;br /&gt;3) We're gonna be tinkering around with better magnets and their effects, along with RFID tagging, as long as neither becomes cumbersome to the functionality of the sequencer. &lt;br /&gt;&lt;br /&gt;4) Everyone gets a &lt;a href="http://abcnews.go.com/Business/PersonalFinance/story?id=3780185&amp;amp;page=1"&gt;free taco&lt;/a&gt;! (pending Taco Bell's sponsorship). &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Anyways, that's where we've been and where we're planning on going. Check back often for pictures, updates, and celebrity gossip.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/411157468520755607-1242802077644559820?l=pseq.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=ebc14eec7a923b18&amp;type=video%2Fmp4' length='0'/><link rel='replies' type='application/atom+xml' href='http://pseq.blogspot.com/feeds/1242802077644559820/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=411157468520755607&amp;postID=1242802077644559820' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/1242802077644559820'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/411157468520755607/posts/default/1242802077644559820'/><link rel='alternate' type='text/html' href='http://pseq.blogspot.com/2007/11/sound-cubes-redux.html' title='sound cubes, redux'/><author><name>myg3000</name><uri>http://www.blogger.com/profile/02275784179300760298</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
