Showing posts with label coding. Show all posts
Showing posts with label coding. Show all posts

Friday, March 6, 2015

Wednesday, December 10, 2014

Coding on a Snow Day!

















I spent most of my day puttering around in the basement, trying to figure out how to add a temperature sensor to the project that I've been working on.

Today marks the third official work day that I've spent, attempting to learn how to code a Lily Pad Arduino. After a great deal of trial and error, I was finally successful!

Here is a link to the code that I used.  I wrote part of this code (the notes for "Baby, It's Cold Outside" and the code for the motor and sensor), but I borrowed HEAVILY from an Instructable that I found in order to get my to sync up with my music.

Saturday, December 6, 2014

Lily Pad Coding Day 2: My Music and Lights are in Sync!

The video below might not look like much, but I spent nearly all day today getting my Lily Pad to sync up with flashing green and red lights!

Here is a link to the code that I used, which is a combination of the music I coded last week (see previous post) and someone else's code for the lights.

The biggest problem that I am having at the moment is that there is a long pause at the end of the song and a couple of lights are flashing for reasons I cannot figure out.

My next step is to figure out how to get the music to turn on with a temperature sensor.







Sunday, November 30, 2014

Baby, It's Cold Outside (LilyPad style)

Lilypad with conductive thread by sameerhalai, on Flickr
Creative Commons Creative Commons Attribution-Noncommercial-Share Alike 2.0 Generic License   by  sameerhalai 

In a previous post, I shared the first musical composition that I coded for my LilyPad, a lullaby that I used to sing to my daughter.  Over the weekend, I sat down and started coding the song "Baby, It's Cold Outside," to get myself in the holiday spirit!  I used this frequency chart to match the notes on the sheet music.  Ideally, I'd like to create a scarf that plays this song and flashes multicolored lights when the temperature dips.

I haven't yet figured out how to program lights to flash in sync with my music, but that is next on my list.  Here is the code that I wrote.

The video is less than thrilling, but you can hear how my song is progressing.  I would appreciate any feedback you might have.