Friday, October 19, 2007

Arduino Day One

So I started playing with the Arduino board today. Darcy has kindly lent me his Arduino NG board so that I can start to learn the interface and some circuitry before we head out to Montreal. I started by following this tutorial, which I had posted a while back.

The tutorial started with a very basic circuit, controlling one LED... basically following a very simple example in the Arduino software and turning the LED on and off. Here is that result:





I then added a second LED to the circuit, and modified the sample code in Arduino to change up the pattern of the 2 blinking LED's:



Here is the code written in Arduino.



Video of the 2 blinking LED's.



Next I added a third LED. Modified the code again and started to play with different patterns. Here it is:



The new code, written in Arduino:





Next, Walter had the idea to hook up a speaker in place of one LED. The first video is pulsing the speaker for 25ms (milliseconds).



This second video is pulsing the speaker for only 1ms. You can start to notice the different "beats" that it creates.



Lastly, my circuit was a bit messy I thought... so I decided to clean it up and make it more legible. I feel better now.



Tomorrow I'll be on to some more complicated stuff. Arduino is fun.

2 comments:

Unknown said...

Looks great Evan, seems like your picking Arduino code up pretty quick. Glad to see you experimenting. Its not that complicated, eh?

Evan Marnoch said...

Eh Josh! The coding isn't so bad to start with, no. Pretty simple and the great thing is that it is completely open source, so even some of the more complicated stuff you can sort of just appropriate and modify it to your needs.