December 12, 2004


I've spent the past week or so playing with my midi library, coding and composing. The coding I've been doing via Python and the first idea that popped into my head was to try to use a class based on a six-string guitar to select a chord and "strum" to produce midi notes. Iterating with the code and cut-n-pasting in GarageBand, I've come up with a composition of sorts. Now I know what they mean by never finishing a composition...I just want to keep tweaking it...

Anyhow, it's a two minute acoustic guitar & piano piece: strum_two.mp3. I hope you enjoy it.

December 09, 2004

Music/MIDI & Mac

The idea of using my Mac for creating music has been a thought in the back of my head for a long time. Finally, I put enough time into coding to make a real set of tools. This post describes my last month of progress in the hopes that this will be helpful to others.

The basic idea was to create music using UNIX basics, my own algorithms, MIDI and a synth. A year and a half ago, I used the echo.cpp example code to create a set of code that uses stdio via a text format to send/receive midi events. I called them mid2txt and txt2mid. However, synthesis at that time for me was just not that interesting--I had no synth! So, those tools went up onto the virtual shelf and were ignored after a bit of noodling.

Apple helped the situation out in a huge way with the introduction of GarageBand earlier this year. Finally, a synth and sequencer. I loved it, but when it was introduced, I had no time. And when I did try my txt2mid program, it didn't work with it and I couldn't figure out why.

Fast-forward to November. I had just received an Oxygen-8 keyboard and was having a bit of fun playing with it & GarageBand. Soon enough, I started thinking more about writing programs...

Looking around the net, I finally read that I needed to create/use a virtual midi source in my code. After finding the code here, it was simple enough to get txt2vmid working. For a moment, I thought all the pieces were in place...

But, the next problem came from timing the midi events. The problem was, no matter what I tried, I just could not get my code to get a proper timing loop in order to send the midi events when they should be sent. Basically, I got within 0.01s most of the time, but every once-in-a while a delay of 0.2s would pop in and destroy the sequence. It got even worse when I actually turned GarageBand recording on. Grrrr, I was pulling my hair out.

Googling & searching the coreaudio email list took a night or two before I found this post. Ah, what a brilliant idea--use a round-trip through the OS midi server to get the timing right. I modified txt2vmid in a couple hours and it worked like a charm. Woo-hoo! The timing was dead-on and recording in GarageBand is only a little annoying because I need to trim/align my input sequences after each recording.

I'm on my way now, having fun creating music with Python. Soon, I'll try to have something to put out there, but in the meantime, as kharmic payback for the virtual help I've received, I'm releasing my code for others to use. Grab it from UPDATED! if you'd like.

Please send me email ( if you use it, though. I'd appreciate knowing.

December 06, 2004


I just received my first patent!

I'm so excited. Did I mention that I just received my first patent? ;^)

December 03, 2004

interesting artwork

I recently found out that one of my co-worker's wife is an artist. Her website is here:

The pictures make me wonder how these would look in the context of a mobile or some other kinetic art.

Photo websites worth a look...

Stumbled on these yesterday via slashdot. The first one has a good
reputation for quality & has interesting ways to get cool photo
hardcopy output (5"x30" panels mounted) and the 2nd one is an
interesting photo-sharing place.

December 02, 2004

Windy Cannon Beach

Wendy & Stuart, originally uploaded by rogerallen.

Here's Wendy & Stuart last week struggling backward against the wind on Cannon Beach, OR. Quite windy that day.

I like how this one turned out.
Check out my page on here