Moving Time

Dear readers,

I’m happy to announce that my new website is up and running! In addition, I’m migrating my blog away from to the new site. It’ll live at from now on. I’ll leave this site up for a week from today, but no new content will be posted here. If you like what I’ve written so far, please feel free to subscribe to the new blog by email!


Your Humble Narrator


Bridging the Gap: Cross Compilation for ARM

There comes a time when the tools are available to complete a task but the way forward isn’t exactly clear. More exotic tools often lack complete or generalized tutorials, and it falls to the individual to find out how to use them for their own purposes without explicit guidance from others. Of course, it doesn’t have to be this way; so here’s another tutorial for you all on how to set up an ARM cross-compilation environment on Linux.

Continue reading

The Evolution of the Editor

I program a lot. A lot. For me, a good editor for code is an essential part of my computing toolkit. It has to be fast, understand my primary languages C, Python, and Java, and have a set of features that let me be a more productive programmer such as autocompletion and documentation lookup.

For a long time, I used various IDEs that were designed to provide exactly that. I used NetBeans for most of my editing all through my Freshman and half of my Sophomore years in college. After that, I used Eclipse. My issues with both of these environments were the same: a lack of easy extensibility. I want my editor to be able to integrate well with all of my tools.

For example, both of the IDEs mentioned above were aimed primarily at Java developers and while they have extensions to enable editing Python and C, they’re frequently not very good. PyDev for Eclipse never seemed to work well for me, and using such a heavyweight editor for writing small, light Python seemed like overkill.

That said, they definitely have some nice features: project management, integrated code browsing, GUI designers, mouseover autocomplete and documentation, automatic generation of build rules, and run/compile support all come to mind. It would be nice if I could have an editor that worked faster and still provided a lot of these features. I decided it was time to go searching for a solution.

Pretty colors, no?

The solution that I came to was Emacs. Emacs has extensibility at its heart and soul; for anything that you might want to do, Emacs probably has something written that you can use right out of the box. This focus on extensibility is what drew me to it over vi; while it might be a more bloated editor, it hardly matters on my quad-core 8GB development machine. It boots ages faster than Eclipse and is more stable; and with my additions (made easy by the availability of packages and the easy .emacs file), it supports most of the features that I used in Eclipse.

My Emacs setup is currently heavily Python-oriented, as I was working on a Python program at Google when I switched. It includes autocompletion, semantic parsing, project management and refactoring, code browsing, syntax highlighting, and all of the usual Emacs goodies. I’ve tried to keep the number of elisp packages installed through the package manager on Ubuntu to the minimum so that I can keep all of my important extensions in one place. This lets me put the entire directory under version control and replicate my setup across machines easily. I’ve even put the git repository on GitHub if you’re interested!

So far, I’ve integrated YASnippet, the Emacs Code Browser, PyLookup, Rope, Pymacs, auto-complete, ido, linum, and CEDET into a full-featured editing environment. It’s working really well for me so far, and I would highly recommend considering Emacs if you’re looking for something lighter-weight than Eclipse.

Musings On My Summer

Well, it’s been a while since I’ve posted! Probably time for an update, huh?

As some of you may have figured out, I’ve been working for Google since May. It’s been a good experience, and there’s lots of free food! I’m working on the Commerce Systems/Billing team, creating reporting tools that help our engineers provide even better service for customers. The whole experience has been rather enlightening, and I’m very grateful for the opportunity. I have about a month and a half left on my internship, and then I’ll be heading back to CC for my last year of undergrad study!

But, before I get there, I’m planning on adding some new equipment to my arsenal. I’ve made quite a bit of progress on building a RepRap 3D printer, and I’m quite excited to see it print! I have the frame built, the motors moving, the firmware compiling… The only set back being that I inadvertently burned out one of my Pololu stepper drivers. I’ve got two on order, so hopefully that will be remedied sometime in the next week. In the meantime, I plan on finishing the Cartesian Robot portion of the machine, and testing it with the various host software options to see which I like best. Stay tuned for more on that.

In software news, I’ve started really digging into Python. I’ve bought a copy of “Programming Python”, a beast of a book which covers most of the advanced usage I’m interested in. To that end, I’ve started writing some small scripts to help make things easier day to day. For example, I’ve written one that sends me an email when my server needs to have updates applied. Python is a ton of fun, and I’d highly suggest it to anyone wanting to put some play back into their programming.

To make writing Python scripts easier, I started looking for a new editor. Eclipse is great for larger projects with lots of source and provides some really nice features, but it’s heavy and slow and doesn’t lend itself well to the fast development that Python promotes. I decided having a lighter environment would be beneficial, so I turned to Emacs. I’ve been using it for the past 2 weeks at both work and home, and I’m really enjoying it. I think I might spend some time learning Lisp so I can extend it. I also need to get a good functional language under my belt…

So, in any event, my summer has been pretty good. My only complaint is that Ann Arbor is too far away… My girlfriend was accepted to the University of Michigan’s Artificial Intelligence Laboratory as a PhD student, and she’s been there since June working on a robot navigation system. I’m incredibly proud of her and somewhat jealous!

I’ll try to pay a little more attention to the blog now that things have settled into more of a routine; keep an eye on it for updates on the projects!

(P.S. I’m also on Google+, so feel free to drop me in a circle if you feel so inclined!)

Working Quickly

Sometimes, writing software can be a pain. It’s unfortunate, but true. Sometimes there’s a need to be filled, an itch to be scratched; and though it might be quite simple in concept, it’s often hard to translate that idea to code. Luckily, the team at Ubuntu has a tool for that: Quickly.

Quickly isn’t a new tool, but it is a useful one. The idea is to provide a shell command which will help take some of the obstacle out of programming for Ubuntu by automatically generating a PyGTK project’s boilerplate code for you. Just entering quickly create ubuntu-application foo creates a directory foo and adds the basic code needed for a simple GTK+ application. It even initializes a bzr repository for you and commits a first revision.

The tool aims to make some “opinionated decisions” about what is a good way to start. I think that’s a good way to go; it certainly makes getting started easier. Although the choices aren’t necessarily the best in my personal opinion (as you probably guessed, I prefer git), they are reasonable defaults and it’s even possible to change them using Quickly templates, which can be created by the user to match their favorites.

The arm control software, written in Python and GTK+.

The main downside, however, is the lack of documentation. There is a team working on writing some on Launchpad, but so far it’s rather sparse. Even knowing how to hook up the GUI to your custom code can require a fair amount of research, and it takes a little of the ease out of using the framework. That said, once you’ve familiarized yourself with the workflow and the structure of the generated code, it’s not too hard to ramp into productivity. I’ve even been using it to work on the robot arm’s control software.

Personally, I think it’s a great idea. It would be nice to have a GUI for it (I reflexively close terminals when I’m done with a few commands, and getting back to the right directory is a pain), but that could easily be written using Quickly itself! While it’s not a new language or even a new toolkit, it is a convenient synthesis of extant tools that have the capacity for powerful projects and are easy to use.