Categories
Uncategorized

Twitter Monkey

Twitter Monkey

Behold… the Arduino Powered Twitter Monkey!

The Twitter Monkey is powered by an Arduino and two servo motors. He patiently monitors Twitter for a specified keyword, and when he sees that keyword, he goes bananas, flapping his arms up and down like a maniac. (For his debut at Web414, the keyword is web414.)

Twitter Monkey was made possible with materials from Adafruit Industries and the local Dollar Tree. The code is heavily based on Alertuino code from MCQN Ltd., creator of the Bubblino.

Update: There’s also a video.

Categories
Uncategorized

Defending Perl

I stand here today not to condemn Perl, but to defend it… Perl

And when I say “Perl” I want you to feel free to substitute any other language you see fit… Visual Basic, Fortran, Lisp, COBOL, Smalltalk, or even… Java.

I was given a programming assignment this week. Given a list of 2000 names, I was to provide 400 names randomly. (Yes, this was for work, and was a real-world assignment, not just some exercise.) I proceeded to open my ~/scripts folder, which contains well over 1,000 Perl scripts, and grabbed some existing code, and wrote some new code, and ran a few tests, and quickly had the list of 400 names.

I used Perl because it worked for me. I probably could have written in it PHP (as it’s another language I am pretty comfortable with) but since I’m more familiar with Perl, and have done very similar thing before with Perl, and had a gigantic library (nearly 15 years worth) of Perl scripts to pull from… I used Perl.

I’m sure others could tell stories just like this substituting Java, or Python, or Erlang, or whatever they have around, that they are the most familiar with… and that’s fine.

This is about using the appropriate tool for the job, and this case, with the job being performed by me, the tool was Perl.

I wasn’t creating some new framework, or building upon an existing application, or pushing some code to GitHub that I wanted others to collaborate on… it was a quick ‘n dirty task that needed to get done as fast as possible.

Much of the programming world (maybe it’s mostly in the web-programming world) gets hung up on the latest and greatest. There’s a chance that using Ruby someone could have completed this task in half the time… but that person would not have been me, as I’ve spent probably less than an hour using Ruby and I’m not familiar enough with it to bang out the needed code quickly. I’d like to have some time to dig into Ruby (or, whatever, pick a language) and get familiar enough with it to use it effectively, but I don’t know when that will happen.

I’m not even a programmer… I’m a hacker, and I think Perl is a hacker’s language. Make something work. Solve a problem. Do it quickly, and move on.

To some degree you could say I’m trapped in Perl, because it is so easy for me to get what I want done quickly, and yeah, there’s a module for almost everything… Where I mainly feel the pain is when I look for example code and narrow my search to Perl (or PHP) because I’m most familiar with them. I needed some code this week to do some serial port communication, and found only one good example written in Perl. I should probably task myself with re-writing the code in Ruby, or Python, or some other language I’m not as comfortable with as an exercise in forced learning.

And then there’s a part of me that just says “screw it, I’m gonna work with what I know, and get things done, and move on.”

Categories
Uncategorized

Fun with the Arduino

Arduino Uno
Photo by adafruitPublished under a Creative Commons by-nc-sa License

The Arduino is a microcontroller, but it’s better described as “an open source electronics prototyping platform.”

And what does that mean?

The term “open source” is usually applied to software, and in that context it refers to software that is free. Not just free to download, but free to modify as you wish. (There’s some distinction between “open source software” and “free software” but I won’t get into that here. It’s safe to say that both of them give you the rights to make changes to the software.)

As for the “electronics prototyping platform” part of it… That’s what it is. A platform for building things with electronics. If you’ve built your own microcontrollers in the past, the Arduino may not be very exciting, but for beginners, or people looking for a platform to build upon, it’s a good thing. (And the open source part makes it even better.)

So what can you do with an Arduino? Here’s a few ideas…

Those are just a few of the interesting projects I came across in the last week. There’s also a nice long list of Arduino user projects in the Playground, and I’ve started to collect Arduino links.

Where can you get one? Adafruit Industries is one place, Maker Shed is another, and SparkFun is another. (See the SparkFun Buying Guide.) If you’re just getting started, I’d recommend the Arduino Uno (which was just released in fall 2010.) Since the Arduino is “open source” hardware, there are also clones you can buy, and each has strengths and weaknesses… but if you just want to start playing, get the Arduino Uno.

Right now I’m just working through a lot of tutorials, writing test code, having a bit of fun, and thinking up some interesting project ideas… How about you?

Categories
Uncategorized

Fritzing – Breadboard Illustrations

Fritzing is an open-source initiative to support designers, artists, researchers and hobbyists to work creatively with interactive electronics…

Since I’m a n00b who can’t read schematics, the breadboard view is good for me… Lady Ada uses it in some of her tutorials.

So if you’re just getting into Arduino hacking and can’t read/write schematics, give Fritzing a try… you may get something like this:

breadboard

Here’s my first attempt at a breadboard illustration. This is for a sketch that reads data from the photocell, and lights up the LED if it’s too dark in the room. Oh, and if it’s too bright in the room, it makes the piezo buzz. Pretty darn simple. I’m not 100% pleased with my illustration, but it was my first time, and since I’ve built this more than once, I guess it should be considered a success.

The Fritzing site has a list of projects and the application (and web site) encourage you to share your creations (under a Creative Commons license even!)

Oh yeah, as for calling myself a n00b, I took a number of electronics classes when I was in school (which was a long, long time ago) but I’m finally getting back into this stuff, and it’s exciting. More updates to come!

Categories
Uncategorized

Welcome to 1984, Apple

I think I first heard the phrase “The network is the computer” in the late 1990s. It was Sun Microsystems who wanted to convince us of this. I worked at a creative agency at the time, where we had pretty powerful Macs on every desk. We thought, sure, a dumb terminal or “network computer” was fine for office drones doing their menial tasks, but creatives needed more power than that… we needed to connect scanners, and color calibration devices, and weird disk drives, and work on ginormous Photoshop files, and things that required more than the VAX terminals we also used at the time.

Fast forward 15 years and what Apple has effectively given us is… a computer that looks like it’s nearly useless without a network. Hello MacBook Air. Don’t get me wrong… it’s a well designed piece of computer. The fact that it weight almost the same as an Eee PC I bought 3 years ago is not lost on me… nor is the fact that the user experience is probably 10 times better. But I still worry about where we are headed…

The MacBook Air has it’s place. But I just can’t help but feel like while hacker/maker culture is moving in one direction, Apple sometimes seems to be moving in the other… creating these sealed boxes that are definitely easy to use, but harder to open. Steve Wozniak must be turning in his grave. The Apple ][ was like the ultimate hacking machine when it came out… and now you can’t even connect a FireWire video camera to the MacBook Air.

In all this I hope Apple doesn’t forget it’s core creative audience. The ones who need Mac Pros, and need to install dedicated cards, and more drives, and tons of memory… The content creators. While the iLife suite gets these great improvements, many of us worry that the Pro Apps are being neglected. Does Apple take us for granted? Knowing that we’ll upgrade Final Cut Studio no matter what?

In the old days you could actually upgrade your computer instead of just getting rid of it and getting a new one. (You could even upgrade the processor!) I’ve been a fan/customer of Other World Computing for many years, and upon reading their write-up of Apple’s “Back to the Mac” event, it saddened me a bit:

Apple seems to be making things easier and more intuitive as well, but seems to be more enabling rather than empowering lately. We want to email our photos, Apple makes it drag and drop easy to put together one of four pre-made collages from our photos and pick an address to send them to. We ask for better tools to make videos, they hand us pre-built effects rather than tools to adjust them ourselves. We want to share our photos with our friends on Facebook, Apple automates and organizes it all for us. Are we as consumers going to gradually lose our ability to do traditional computing (using and upgrading) for ourselves as we conform our computing lifestyles to Apple’s one size fits all templates … and, as a result, is 1984 coming full circle?