Monday, August 31, 2009

Designing For Lower Literacy Users

Addicott Web has an insightful article up about designing for low literacy users. This isn't a term I had heard before, and conjured up images of designing websites for folks who can't read text. Why I needed to know this, was beyond me, but I decided to read the article anyway.

Good thing I did, as my assumption was completely off. Here's what a low literacy user is:

The most important thing that I can emphasize up front is that when I use the term “lower literacy”, I’m not talking about people who are illiterate or unintelligent. Quite the opposite in fact. People who have a lower literacy are able to read – they just struggle with it to some degree depending on the particular medium in question. In this case, I’m talking about lower literacy as it pertains to websites.

In general there are some common characteristics of people who have a lower literacy:
• They have trouble scanning text
• They need to go through content word-by-word
• They’ll often find themselves re-reading long, unfamiliar words

In other words, he's describing our parents when sitting at a computer! (OK, well not exactly my Dad who's been using the web since the days of Gopher).

And here's the big deal: you can do things to your site or software to make it more friendly to this type of user. At the very least, when you're having folks evaluate your site, you can go out of your way to include some users who fall into this category to get a true picture of how accessible your application is to the world.

Like I said, the article is definitely worth a read. Or, if you're a high literacy user, a quick scan for keywords.

Definition: You've Been Sevened

To be Sevened is the process of trustingly following the instructions of your GPS, only to surprisingly end up on a route you know to be the slowest one possible. This term is derived from the always-slow Route 7 that runs through Falls Church, VA.

Usage:

Alice: So, I'm driving along, following the GPS instructions to my dentist appointment, when bam! I realize that it wants me to get off and take Main St the rest of the way.

Bob: D'oh! You've totally been sevened - I'm so sorry to hear that. Looks like you have no choice but to sit in traffic and be late to your appointment.

See also this unrelated defition.

A Thought About Edward Kennedy

If you haven't yet, give Obama's eulogy of Senator Edward Kennedy a watch:

I've not really followed the whole Kennedy saga, so much of the media blitz going on now is beyond me. But, what struck me about Obama's eulogy was he didn't attempt to gloss over Kennedy's short comings, but that he emphasized it was exactly these short comings that made him into a better person. He found a way to turn his failures into a source of strength for his successes.

I'm all for honoring, and learning from that example. In fact, I can't think of a more honorable trait for a person to have.

Appalachian Trail: Annapolis Rocks to Pen Mar Park - Route, Food and Gear

Here are some notes from our relatively short trip up the Appalachian Trail.

The Route


View Annapolis Rocks to Pen Mar Park Hike in a larger map

We found the section of Appalachian Trail from Annapolis Rocks to Pen Mar to make for an excellent 3 day adventure. We got the idea from the book The Best of the Appalachian Trail Overnight Hikes, 2nd (see page 96).

The trail was very well marked and offered some sweeping views. The route gives you access to 3 AT shelters to use in an emergency and enough water sources we never felt (too) worried about finding our next drink.

The route was quite rocky in some areas, which made for a challenge at times. Though, I actually enjoyed the change of terrain and thought it spiced things up a bit. Definitely plan for some slow going during parts of the route.

We camped the first night at Pogo Memorial campground which made for a first easy day to start things off (about 5 miles of hiking). Then, we did about 10 miles the next day and camped near the Devils Racecourse shelter. Both sites had water and offered fire pits - which we made excellent use of, if I do say so myself.

It had been years since I had done any real backpacking, and this was an excellent route to get back into the swing of things.

You can view a map of the route, and grab key waypoints from our trip here, including a KML file to load into your GPS.

The Food

Food is one of those aspects of backpacking that I find both tricky and easy to ignore (till its too late). The big question I find is, how do you bring enough to not be hungry, but not so much that you'll be weighed down unnecessarily. All the lightweight packing in world won't help you if you throw in excessive amounts of food and water.

Surprisingly, we did exceedingly well this trip. Here are a few items that really worked:

  • The first night we did hot dogs cooked over an open fire on sticks. Hot dogs are heavy, but our first hike in was short and they were a huge treat. One package (7 hot dogs?) fed the three of us, with no left overs. Oh, and don't do what I did and forget the packets of mustard.
  • The second night's dinner consisted of a variety of instant rice noodle bowl meals (like: Thai Kitchen). These were great: when removed from the bowl, they took up almost no space and weighed nothing. They've got reasonable taste, and need nothing but hot water to cook. It was like buying fancy dehydrated meals, minus the cost.
  • Gorp: I found about a 1 quart ziplock bag filled with nuts and various dried fruit items purchased from Trader Joe's worked well for me. David was convinced I brought too little gorp, because I was done with my bag when I completed the hike. But for me, no left overs means it was dead on perfect.
  • Energy Bars: I found setting aside 2 energy bars per day worked well without getting tired of eating food in bar-form. Lara and Pure bars were my favorite as they are both very dense (physically and calorically), satisfying and don't melt in the heat.
  • Packages of cheddar and wheat crackers are a favorite of mine. Though, they are fairly fragile. One package during lunch mixed things up a bit.
  • Jiff makes small cups of peanut butter that worked great. 1 small cup fed all three of us for lunch. Given how many calories one cup has, extra one of these throw into the mix made for a nice emergency food source.
  • For water, we found that iodine tablets worked well to purify it. What made this method work so well are the extra neutralizing tablets you add to the water after it's purified. They worked like magic, with the water going from clear to nasty-yellow with the iodine tablet, back to clear with the neutralizing tablets. We even tried a water filter that a neighboring scout troop had, and found the exhaustion of pumping water to be way more trouble than just waiting 30 minutes for the iodine to do its job.

The Gear

I used every item I packed, with the exception of: the sheet of tin foil, safety pins, the band aid, the compass (like I said, it was a clearly marked route!), the whistle and the emergency blanket. Considering the emergency nature of many of these items, and how lightweight they are, I was quite pleased. On the flip side, I never felt wanting for anything.

My pack had a base weight of about 11 (ok, maybe 12 pounds) without food, and 17~18 pounds with food and water. How or Why I used to backpack in scouts with a 40 or 50 pounds pack is beyond me. What the heck was I thinking?!

Here are some notes on specific gear that did or didn't work. I've already updated my gear list, so I'm ready for the next trip.

Note: if an item is on the gear list, and not mentioned below, it means I liked it and will continue to carry it in the future.

Foam PadReplace ItMaybe I'm getting old, or something, but I found sleeping on this basic foam pad to be really uncomfortable. Time to upgrade to something more luxurious.
Pack - Osprey Exos 46Love It!This pack rocks. Not only is lightweight, and manages to fit all my gear with room to spare, but I found the pockets, straps and other features totally worked for me. For example, the waist belt pocket fit my camera perfectly, and the shoulder strap pocket held my GPS like it was custom built for it.
BlanketBring ItShira and I shared a queen sized, lightweight blanket I picked up at Target a while back. This worked out better than I expected - we were both warm, and only one of us had to carry an extra 2lbs (maybe less) to account for it.
Photon Microlite IILove It!This light is amazing - it's tiny, cheap and works better than my heavy mini-maglight I used to carry. Buy one today.
Emergency BlanketBring ItThis is an item I've always carried and almost never used. But this trip, I realized just how silly this is. There's a million uses around camp for it: cover wood to keep it from getting soaked in the rain, cover rocks after the rain to provide you with a dry place to sit, wrap your pad up in it to provide a way to keep it dry when dangling from the outside of your pack, etc. But, the thing is - it's so perfectly folded, and becomes a big mess when unpacked, that I leave it untouched as to not have a hassle on my hands. But no more. Next trip, I'm unpacking the blanket ahead of time, and then stuffing it into the tiniest ditty bag I can find. I'm going to finally get some use out of this handy item.
Painter's Drop ClothBring It I picked up a 9x12 foot, plastic painter's drop cloth to bring as a ground cloth, and it worked remarkably well. Besides being cheap and lightweight, it's something we can discard at the end of the trip and replace with a new one easily.
MSR PocketRocket StoveLove It!This stove is amazing. It's lightweight (3oz!) and cost only $40.00. But the amazing thing is just how much heat it puts off. We had water boiled in just a few minutes. Bonus: the thing sounds like a jet engine taking off.
Garmin Geko 210Bring ItThe Geko can be a bit of mixed bag to hike with. On the pro side, I'm able to preload waypoints to serve as a fallback navigation method and capture new waypoints to use in documenting our trip after the fact. It also gives me some basic trip functions like tracking how many miles we've walked, distance to a future waypoint and items like sunset and sunrise. On the con side, it does a cruddy job of keeping satellite reception. The result is that I found myself taking the GPS out of the pocket it was in and waiting for anywhere between 20 seconds and 5 minutes to have it rediscover satellites. Still, given its size, and the benefits it provides (especially from an emergency perspective), it stays. Maybe it's time to look at a forerunner?

Sunday, August 30, 2009

Appalachian Trail: Annapolis Rocks to Pen Mar Park - Photos

Our trip up the Appalachian Trail was a big success. The forcasted weather of 3 days of rain turned out to be one big thunderstorm, one medium sized down pour, and some overcast skies. In other words, it was a joy.

More to come about the route and gear we took. To learn more about the trip, check out my notes about the route, food and gear used in the trip. But until then, Here are some photos from the trip. We definitely had a blast.

Update: Added a link to more notes about the trip.

Thursday, August 27, 2009

3 Thoughts On The Scheme Standardization Effort

Here are some random'ish thoughts that the chatter about the new scheme standard process has triggered.

What to call it?

A humorous thread that's popped up about what to name the different flavors of Scheme. Rather than Large and Small Scheme might I suggest:

  • Small Scheme and Tiny Scheme
  • Small Scheme and Smaller Scheme

The emphasis being, of course, that even a complete implementation of Scheme should remain as compact as possible.

What Goes In The Small Scheme

I can see the debate about what belongs in and out of the small version of scheme is already heating up. My initial reaction was, of course it needs a module system, and I'm sure others would say the same thing about a standard record system. And on, and on, till you end up with standard nobody's quite happy with.

Thinking about it further - I'd suggest the following. Scheme has 3 fundamental abstraction building blocks: closures, macros and continuations. Want a module system? Combine closures and macros. Want exceptions? That's really just continuations and macros.

Why not focus on making these three features as absolutely strong as possible in the core, and leave it at that. Closures I think are pretty much nailed. Continuations, I'm not so sure about. And switching from syntax-rules to syntax-case seems like an absolute no-brainer.

I could also see adding some sort support for tweaking the reader. But other than that, I'd stop there.

As a sort of working demonstration of this small standard, I would publish SRFIs that demonstrated the code needed to implement the more sophisticated features of the larger scheme. For example, the larger Scheme may call for exception handling, therefore, write a module in the smaller scheme that implements this same functionality.

The Real Winners In The Debate

While there's a fair amount of debate about what belongs in the skinny standard, there hasn't been much discussion (that I've seen) about the larger standard. And perhaps that's the real benefit of this whole effort. By splitting the language into two flavors, it takes the pressure off of those who want to see Scheme grow, while still staying true to its roots.

Seeing as I actually use Scheme in my day job, and benefit from advanced features that show up in PLT-Scheme and the like, I'm glad to see a more complete scheme get standardized.

In other words: let tiny scheme be the arena for religious debates, and let small scheme be argued along pragmatic lines.

An Instant Admin Interface

I'm starting on a new site for a client that calls for a fairly significant amount of back end data. Unfortunately, the client's budget doesn't cover the creation of an admin area where she can enter this data in. My first thought was that I'd have her send me the data as a csv file and I'd cram it into the database myself. But, at about 2am last night as I was heading to bed, a novel solution hit me.

What if I had the customer add in the data on a Google Spreadsheet and then pulled the data dynamically into the system using the Google Spreadsheets API. What would make this a real win is that I could require the spreadsheet self describing, which would allow the code that I write to remain completely generic (and reusable). The result: anytime I want a quick and dirty way for customers to maintain data, I just wire a database table up to a Google Spreadsheet.

The Implementation

After a couple hours this morning, I had my generic synchronization procedure implemented. Here are the assumptions I make that drives the process:

  • The worksheet tab name is the same name as the database table to sync with
  • The column heading of the spreadsheet correspond to the column names of the table
  • The first column must be a unique identifier into the table (though, not the primary key - that will just be an auto incrementing number)
  • The database table must contain a column named expired. This will be set to a timestamp when an item is removed from the spreadsheet, and is set back to null when it's added in. That way, the spreadsheet can appear to delete records, but can't really.

Using the above approach, I'm able to write a fairly simple series of functions (about 55 lines of code) that does the synchronization. I then gave the customer a page she can visit to resync the data. Down the line, I suppose I could wire this into a cron job.

Why It's So Simple

One of the features that Google provides that makes this especially simple to implement is their list based view the spreadsheet data. The first time I heard about this I was confused - why would anyone want such a simplistic view of a spreadsheet, when you can access rows, columns and ranges? But, it turns out, for applications where you just need to slurp down data, it's a huge win.

Specifically, using list view you can easily get an array of spreadsheet rows, where each row object has a map that contains column, value pairs. Or, to put this in code form you can say:

// See the <A href='http://framework.zend.com/manual/en/zend.gdata.spreadsheets.html'>Zend API</a>
$query = new Zend_Gdata_Spreadsheets_ListQuery();
$query->setSpreadsheetKey($spreadsheetKey);
$query->setWorksheetId($worksheetId);
$rows = $spreadsheetService->getListFeed($query);
foreach($rows as $row) {
  $rowData = $row->getCustom();
  foreach($rowData as $col) {
    echo $col->getColumnName() . " = " . $col->getText();
  }
}

This makes the synchronization process as easy as iterating through this list of rows and converting each entry to either an INSERT or UPDATE statement.

The Pros and Cons

The big problem with this approach is that it's fragile. This is especially true if data in on tab of the spreadsheet is intended to join up with another one. There's no concept of referential integrity here. But, having the ability to allow the customer to tweak their own data is absolutely invaluable. So for now, I think the risk is worth the reward.

Google Spreadsheets in general offers some interesting features that also make it a powerful choice:

  • The client can invite others (think: intern, assistant) to edit the spreadsheet, and therefore manage the data
  • Users of the spreadsheet can add alerts that lets them be notified anytime the spreadsheet data changes
  • There's version history spreadsheets, which means clients can see a past snapshots of their data and optionally roll back to one
  • Data can be exported for backup or printing, and imported if the client prefers to manage the data in another tool

I was considering posting the code for this solution - but alas, it has to many dependencies on code I'm not ready to make available to the public. If you have specific questions about how I implemented, please feel free to ask in the comments and I'll be glad to respond.

Wednesday, August 26, 2009

Garmin Geko Symbol Names

I wanted to get all fancy and transfer both basic waypoint data and the symbol (icon) to associate with the waypoint to my Garmin Geko

GPS Babel makes this trivial to do. You just need to include a Symbol column when using a format like the unicsv, and pass the appropriate symbol name (common ones are Flag and Waypoint).

What was missing, though, was what the possible symbol names can be. I Googled around and couldn't find this list. So I compiled it manually.

Here you go:

  • Flag
  • Residence
  • Car
  • Campground
  • Waypoint
  • Hunting Area
  • Geocache
  • Geocache Found
  • Boat Ramp
  • Fishing Area
  • Shipwreck
  • Swimming Area
  • Skiing Area
  • Trail Head
  • Skull and Crossbones
  • Medical Facility
  • Telephone
  • Restroom
  • Information
  • Park
  • Scenic Area
  • Picnic Area
  • Gas Station
  • Restaurant
  • Lodging
  • Bank
  • Golf Course
  • Building
  • Airport
  • Parachute Area

Just think, now you can look at your tiny Garmin screen and see just how close your Parachute Area is to your Lodging.

Some Trail Reconnaissance

To make our upcoming backpacking trip as smooth as possible, I've gone ahead and noted various waypoints along the way using Google My Maps. This data came from sites like the Appalachian trail shelter list, hiking logs as well as just inspecting the Google Map itself.

Using GPS Babel, I've taken this Google Maps data and uploaded it into my Garmin Geko. The result? I should be able to find the shelters and other points along the way with a minimum amount of fuss.

If you're hiking the Appalachian trail in the Annapolis Rock area you may actually find this specific map useful.


View Annapolis Rocks to Pen Mar Park Hike in a larger map

Tuesday, August 25, 2009

Lumix TZ50 Wifi: 2 Steps Forward, 1 Big Step Back

I like my Lumix DMC-TZ50 camera quite a bit. Though, the built in WiFi appears to be little more than a joke.

I finally was inspired enough to poke around Panasonic's website to do something about it and here's the progress I made.

The Good News

I had a couple of good things happen with the camera. First, I was able to talk to a human about issues with the camera. She didn't have any suggestions for fixing the WiFi other than resetting the camera. Though, she did say I could continue working with her, and if the camera's WiFi is truly broken, they'll let me send it in to be repaired.

Also, I stumbled on this marketing site for the camera which elaborates on a whole bunch of its features. Now that I've played with the camera a bit, it's probably a good idea to go back and review all these features to see if I should be using other options on it.

Finally, I not only found the firmware update for the camera, but I found the instructions for applying it.

Though the instructions for checking the firmware are different (on the TZ5, you have to do a funky key combination, on the TZ50 you just hit the menu button, go to setup, and click on the show version menu), the actual steps for applying the Firmware worked great.

With the new firmware in place, the WiFi seems just as unreliable as with the old firmware. But perhaps I need to fiddle with it some more?

The Bad News

Though, with all this good news, there was one really sour note. When I received the camera, I got a coupon that said I was eligible for one free year of T-mobile Hotspot. That's a significant offering, and would have effectively lowered the price of the camera $100.

The offer is even highlighted on the microsite mentioned above:

For the life of me, though, I haven't been able to redeem this offer. I've tried following the instructions given (which essentially say, use WiFi in a T-mobile hotspot location), but the camera never properly connects at T-mobile hotspot. I've talked to 4 or 5 t-mobile folks about it, and nobody has ever heard of this offer.

Today, on my the tech support call, I learned why. Apparently, Panasonic canceled this offer back in January. The tech rep muttered something about how Starbucks switched from or to AT&T and that somehow invalidate this offer.

When I explained to her that they were still advertising this offer on their own website, she was surprised, but said there was nothing she could do.

I totally get that offers like this have to end early occasionally. And, I get that the box the camera came in was probably sealed up months ago and that it wouldn't be reasonable for Panasonic to have to recall it just to remove the free Hotspot certificate.

But to continue to advertise the offer 8 months after it's expired seems like a really scummy thing to do. Luckily, I didn't make a buying decision based on this offer - but what if I had?

At what point does Panasonic become guilty of bait-and-switch or false advertising?

Monday, August 24, 2009

Oh, *that* intel

I was walking down the street when out of the corner of my eye I saw the headline: "Petraeus to open intel training center."

My first thought: When did general Petraeus leave the army and join Intel? I bet he runs one tight training center.

Then I scanned the article, oh wait, he is still in the army.

Second thought: what a novel idea, open up an Intel training center in Afghanistan as a sort of way to bootstrap the economy.

Then it hit me: they don't mean Intel, they mean intelligence. Ahhh, that makes much more sense.

For a second, I wondered what AMD was going to have to do to continue to compete with Intel. Whew.

A Solution To Programming Language Growth - Cut The Baby In Half

The folks in charge of the Scheme standardization process have a real dilemma. On one hand, they have a group of users who want the Scheme language to stay tiny. On the other hand, they have another group of users who want Scheme to be more portable and robust for the production programmer. These groups expect completely different things out of a language standard.

The attempt to create a single standard to please both these parties resulted in R6RS - which left people ranging from disappointed to down right mad.

I've actually made my suggestion on how to tackle this for the next version.

Today, I read the position statement from the standards steering committee, and was quite impressed with their solution:

We believe the diversity of constituencies justifies the design of two separate but compatible languages, which we will (for now) call "small" and "large" Scheme.
Small Scheme: ...Think "IEEE/R5RS brought up to the current date."
Large Scheme: ...Think "R6RS with a happier outcome."

There's a 90% supermajority required to ratify the small scheme standard, and a 75% supermajority required to ratify large scheme.

Upon first glance, I think this is really a brilliant solution. To pretend like these legitimate, diametrically opposed, constituencies doesn't exist is to put one's head in the sand. That won't fix anything. But, accepting the situation, and making the best of it, seems quite smart.

I'll be anxious to see how they actually try to pull this off.

Sunday, August 23, 2009

A Home Run Day

Geesh, I know this is tough times in the economy - but you'd think given the size of the lawn the Washington Nationals have, they would at least have a riding lawn mower instead of a push one.*.

What a perfect day for a ballgame! Kicking the Brewer's butt's certainly didn't hurt. In fact, we were treated to 3 Nats home runs, the most Shira and I have seen during a game yet.

Our cousins joined us for the game, and we had an absolute blast. See, here's proof!

*This was a joke - the fellow on the grass here was most likely touching up the shading of the W on the field.

Store Tested, Ben Approved

I've got a backpacking trip coming up, and decided one of the best ways to save weight was to trade in my massive Lowe Contour IV (a beloved pack, mind you) that ways 7lbs for something lighter.

I had my eye on the Osprey Exos 46 pack, which weighs about 30oz. After watching the promotional video, I was sold.

One of the features I like about the pack is that it's small - around 2800 c in. Less space means less temptation to fill it with crap.

But, would the gear I want to bring fit? How useless would it be to have a most excellent pack, and yet not be able to use it?

My solution: stash the gear (minus food) in a stuff sack and bring it with me to try on the pack. I was expecting a crazy look from the clerk - but he totally got it.

Within 3 minutes I had the bag loaded and I confirmed there's room enough for food and water. The decision was made: I'm the proud owner of an Osprey Exos 46.

While stuffing my gear into a pack on the floor at REI was a bit awkward, it was totally worth it, and I recommend this approach to anyone in search of the perfect pack.

More to come on this topic, for sure.

A Beta Quality Lightweight Backpacking List

Weather permitting, I've got a short (3 day, 2 night) backpacking trip coming up. The last backpacking trip I was on was years ago, and while the details are hazy, I recall one clear thought: bring less stuff. Last time I didn't take pack weight seriously, and it was a pain.

This time, I plan to be extra careful. I've gone through various gear lists and used my own past camping/backpacking experience to come up with the following. When I compiled the gear earlier, minus the pack and a few odds and ends (like the camera and swiss army knife), the weight was around 10lbs. So, it's certainly a start.

Speaking of existing gear lists, here are a few that really shaped my list:

  • Brett On Stuff - Brett clearly knows his stuff. His gear list is perfect if you're ready to spend cash and do it right.
  • 3 Days, 10 Pounds - this is a no-nonsense list that provides more ideas for a 10 pound pack.
  • Frank Perkins' Gear List - Frank provides another really complete list. Like Brett, it's more oriented towards those who are ready to buy the ideal gear.
  • Low Cost Ultra-Light Backpacking List - This is a detailed list that shows how you can go lightweight without spending lots of money. Definitely helpful.
  • Travel Independent - What To Pack - These are actually packing recommendations for tour backpacking (think: backpacking Europe), not trail backpacking. But, I found it such an entertaining and thoughtful read, I think it's worth of being on the list.

So here it is - my current 3 day backpacking gear list.

DISCLAIMER: This really is an untested list. Use it as inspiration, not a definitive recommendation

Saturday, August 22, 2009

Catching A Rainbow

I can't remember the last time I saw a complete rainbow, and even managed to have my camera on me. What a beautiful site to see!

Noah's First Blog Appearance

OK, Noah has a good excuse for not showing up here on the blog sooner - he's only been on this planet for about two weeks. But man, isn't he a cutie! It was so wonderful of his parents to let us invade their place, play with him, and let me snap tons of photos.

As we were walking out, we noticed the placement of bottle rack and its proximity to the wine rack. Is there a better metaphor for the transition into parenthood?

Thursday, August 20, 2009

Hardware First Impressions

While traipsing through the mall yesterday, I had a chance to play with some gadgets I've been meaning to handle. Here are my initial impressions - keeping in mind, they were very brief encounters:

HTC myTouch 3G - This is the follow on to my G1. It has the same OS, so it was quite familiar. I could definitely tell it has a faster processor, and the phone was much more responsive. But, no keyboard? What the heck! I can't imagine why the dropped it, as the phone seems crippled without it.

HTC Touch Pro 2 - this phone definitely has the hardware. While I'm not ready to claim it has a better keyboard than the original Sidekick, it was definitely roomy. And the screen was gorgeous. The problem is, it's Windows OS, and I felt like I was moving in slow motion because I'm so unfamiliar with it. This isn't really Windows fault - each OS has it's own nuances. For example, I hit the hang-up key to lock my screen, while Shira hits it to back to the home screen. The result: whenever I pick up Shira's phone, I can't figure out how to get home, and whenever Shira picks up my phone she's constantly locking it. This may be a great device, but I'd have to learn the OS first

Smart Fortwo - OK, this is car, but with it's compact size, I'd say it's nearly a gadget. They had a few of these sitting around in the mall, and surprisingly, the one I approached was open. I was able, for the first time, to sit in one of these.

I have to say, I'm impressed. I didn't feel nearly as claustrophobic as I thought I would have. I didn't get the sense that there was nothing in front of me, or behind me. I couldn't exactly spread out, but I think it would definitely have been drivable.

Ignoring for a second that we don't actually need a new car, there's about a 0% chance I'll be buying this one. The issue isn't that of space - it's of safety. Our conversation about the car quickly descended into one about whether or not it was safe enough. I'm impressed with crash capabilities, but all Shira sees is a tiny car waiting to get stomped.

Wednesday, August 19, 2009

Useful Ant Tips

This article delivers just what it promises - a list of useful tips for Apache Ant.

Some tips I'd add...

  • DO: use the Ant-Contrib package to get access to all sorts of slick plugins
  • DO: use the SQL task to prepare and cleanup your database
  • DO: use the import tag to split up your massive build file into manageable parts

Overall, excellent advice!

Update: DO: use MacroDef to build abstractions that result in more concise and clearer build files.

Script-Fu: Save-It Plugin Improved

A while back I blogged about a Script-Fu plugin I wrote that simplified the saving of png files. The idea being that you edit and save your images as .xcf files and by hitting Control-P a PNG version is saved for you - no questions asked.

I've since improved this a bit to add support for saving a single region as png file with minimal hassle. The steps to do this reduce to:

  1. Create a selection (typically using the rectangle tool and guides to help)
  2. Hit Control+Shift+P
  3. Enter a suffix - for example: top
  4. Hit Enter

If the file above was named foo.xcf, the generated file would be foo-top.png.

The obvious use for this is extracting slices of images for web development. While I could have used the Slice or Guillotine plugins, I wanted something that was simpler and more precise.

Here's the code you'll need to drop into your scripts directory:

Here's the plugin in action:

TweenBots: Robots that need your help

I came across the TweenBots project on AdverBlog. And what is a tweenbot, you ask?

Tweenbots are human-dependent robots that navigate the city with the help of pedestrians they encounter. Rolling at a constant speed, in a straight line, Tweenbots have a destination displayed on a flag, and rely on people they meet to read this flag and to aim them in the right direction to reach their goal.

And they're cute too:

I like this project on a variety of levels. First, it gets creativity points for just thinking of the idea. Second, I find it restores a bit of faith in society - people aren't so self absorbed that they won't take a few minutes to help the little bot on its way. Finally, the practical side of me thinks this human assisted technology is an interesting model. Rather than make an especially complex device, make a simple device with an easy way for people to correct it.

I wonder when they'll start rolling around Arlington?

Monday, August 17, 2009

Elizabeth and Dan Get Hitched

What a pleasure it was to be at my friend Elizabeth's wedding! Everything about it has been superb: from her wonderful groom, to the touching ceremony, incredible food, and super-fun Contra Dancing.

What a treat to be here for the whole weekend, and to get to meet some many of her friends and new family. Everyone has just been a joy. The fact that we are surrounded by beautiful mountains, a cool swimming pond and perfect weather certainly didn't hurt.

Here are a couple photos from the big day.

I wish them nothing but joy and happiness in their new life together. Mazel Tov! (and may you make many trips to the DC area)

Sunday, August 16, 2009

Ben and Greg Hike Silver Lake

In the couple of hours we had between breakfast at the B&B and photos for the wedding, Greg and I squeezed in a quick hike to Silver Lake. The trail head was a few miles drive from the Inn.

The lake turned out to be gorgeous, and the water fall was an added bonus.

The best part, though, was just the joy of getting to hike with a good friend.

And for the record, we made it back to the B&B, showered and still had a couple of minutes before we were needed in our photos.

B & B Camping

The Elizabeth & Dan wedding weekend is full swing, and we're having a blast!

While the first night I slept in a room at the B & B, last night the plan was to tent it with Greg. To my amazement, the tent I brought up had all the poles, stakes, rain fly and even yolks. Heck, there was even a clothesline hanging inside when I set it up.

The night was clear and cool, so I decided to start out sleeping under the stars. I figured if need be, I could flee to the tent or better yet, flee to the nearby B & B. It turned out to be unnecessary. And with the exception of waking up to the sound of a pack of wild dogs howling in the distance (OK, maybe it was an owl), I slept like a baby.

Here are some photos from last night and a little hike I took this morning. Good times, really good times.

Friday, August 14, 2009

The Vermont Wedding Adventure Begins

My good friend Elizabeth is getting married, and if that wasn't exciting enough, she's doing it in a really cool place: Blueberry Hill Inn, located in Goshen, Vermont.

I've only been here a few hours, and haven't had to much time to explore, but man, is it gorgeous.

One note to self - when someone offers me a trail map, rather an assuming the signage is self explanatory, accept it. (See the photo below of the useful trail signage).

I'm currently posting this entry from a cute little bedroom, upstairs in the inn, with a light breeze blowing on me as a rock back and forth in the provided rocking chair. Throw in the Groove Salad that's playing on the computer, and this has to be one of the most relaxing workspaces I've ever been in. Ahhhhhh....

I wish Elizabeth and Dan nothing but joy and happiness in their new life together! Mazel Tov!

If I Ever Consult On A Computer Programmer Action Film...

I'm so going to have the hero ssh into a server from his cell phone, and use various command line tools to save the day.

Whenever I do this (like I'm doing now), I feel like such a rock star.

Oh, and the geek would so get the hot girl/guy in the movie.

Thursday, August 13, 2009

PLT-Scheme: A GUI Accessor Pattern

I stumbled on this Scheme development pattern last night, and thought it would be worth sharing. My guess is that this is probably already a well established (and better named) pattern, but I can't resist sharing it none the less.

The Problem:

I'm developing this small GUI app using MrEd, and was paying special attention to the code that links the GUI objects to the actual logic of the system.

My preference is to try to decouple the GUI widgets as much as possible from the underlying functionality of the system. This allows me to program the logic of the app in a fairly functional style, and not be tied to the nuances of a particular GUI.

I've got a couple of callbacks on buttons that actually kick off the logic of the app, and I ended up passing in GUI widgets themselves into the function that creates these callbacks. I essentially ended up with:

(define (make-buttons frame logging-on?-checkbox algorithm-choice)
  (new (button% [label "Foo"]
                [callback (lambda (b e)
                            (let ([logging-on? (send logging-on?-checkbox get-value)]
                                  [algorithm (send algorithm-choice get-value)])
                              ;; ... do things with logging-on? algorithm
                              ;; that aren't GUI related
                              ))])))

This was OK, because the transition from GUI land to the more functional logic of the app was contained in one spot.

One Solution

It hit me - GUI objects, as a side effect, do all GUI magic at instantiation time. After that, all I want to do is access and set values on them. In fact, wouldn't it be nice to be able to treat them like paremters? That is, access them like they are functions that you can get and set a value from. The fact that they are backed by a GUI control isn't really relevant to the rest of the code.

I quickly rigged up a gui-accessor module:

#lang scheme
(require scheme/gui)
(provide make-gui-accessor mga)

(define (get-value gui-instance)
  (cond [(is-a? gui-instance message%)
         (send gui-instance get-label)]
        [(is-a? gui-instance choice%)
         (send gui-instance get-string-selection)]
        [(is-a? gui-instance text-field%)
         (send gui-instance get-value)]
        [(is-a? gui-instance check-box%)
         (send gui-instance get-value)]
        [else (error (format "Unknown instance type: ~a" gui-instance))]))

(define (set-value! gui-instance v)
  (cond [(is-a? gui-instance message%)
         (send gui-instance set-label v)]
        [(is-a? gui-instance choice%)
         (send gui-instance set-string-selection v)]
        [(is-a? gui-instance text-field%)
         (send gui-instance set-value v)]
        [(is-a? gui-instance check-box%)
         (send gui-instance set-value v)]
        [else (error (format "Unknown instance type: ~a" gui-instance))]))

(define (make-gui-accessor gui-instance)
  (lambda arg
    (cond [(null? arg) (get-value gui-instance)]
          [else (set-value! gui-instance (car arg))])))

(define mga make-gui-accessor)

This is pretty basic code - it provides a single function make-gui-accessor that takes in a GUI control and returns back a procedure. If you invoke this procedure with no arguments you get the value of the control, and if you invoke it with a single argument it sets the control.

I aliased mga to make-gui-accessor to make this especially terse.

Now, in my above example, when I create a check-box I say:

 (let ([logging-on? (mga (new check-box% [label "Enable Logging?"] [parent frame]))])
   ...)

cb above is now ready to be used in a procedure context that doesn't need to know anything about GUI controls.

My function above now reduces to:

(define (make-buttons frame logging-on? algorithm)
  (new (button% [label "Foo"]
                [callback (lambda (b e)
                              ;; Get the value of logging-on? by saying (logging-on?)
                              ;; and the value of algorithm by saying (algorithm)
                              ;; No GUI logic needed here.
                              ))])))

Is this rocket science? Definitely not. But it does feel like a simplification that will make working with a GUI that much easier.

Thoughts? Am I missing something obvious? Is this terrible style? Is this already done? Feedback appreciated.

Two Dreams From Last Night

I'm not usually in the habit of documenting my dreams, but these two were just too whacky.

Dream #1: Can't Sleep

In my dream last night, I dreamt about how I was having trouble falling asleep. Therefore, in my dream, I kept waking up - yet was really asleep the whole time. There's nothing like having a dream where you're worried you're not going to get enough sleep that night.

Dream #2: Going to the movies

Last night I dreamt I was watching G.I. Joe: The Rise of Cobra. There's only one minor detail, I don't know anything about the movie (nor do I have much interest in seeing it).

Luckily my brain was glad to fill in the gaps: two of the main stars, and I'm totally not making this up, were Chris Farley, and playing opposite him, a chimpanzee.

Apparently, my subconscious decided G.I. Joe should really be a slapstick comedy.

Ahhh, I wonder what kind of entertainment my brain has in store for me tonight.

Got an equally whacky dream to share? I'd love to hear it - just leave it in the comments.

Wednesday, August 12, 2009

Cutting Edge Technology, Meets Family Nostalgia

I stumbled on this gadget from Polaroid:

Essentially, it's a portable photo printer that connects to your digital camera or cell phone via Bluetooth. What distinguishes this device from other photo printers out there is that it's inkless - all the magic for generating the print is in the paper itself.

Sound familiar? Polaroid has managed to reinvent the Polaroid print, only this time it has the option of using Bluetooth.

This is almost certainly a toy I don't need. But I have to say, I'm totally drawn to it. See, I've got these fond memories of my Grandpa Arnie snapping photos of my brothers and I with his classic Polaroid camera. And of course, we helped ensure the prints came out perfectly by waiving the photos just right.

Man, that camera was so incredibly cool. Besides having prints that instantly appeared, the whole camera folded down flat making for a most impressive design.

Shira tells me her Grandpa also had a Polaroid camera - guess there were standard equipment for grandparents back then.

Hmmm...I may just have to add this to the wish list.

As an aside, I love this quote from the SX-70 information page:

The Polaroid Corporation will be remembered in history as a company with the best products and the worst marketing ever.

My Latest Senior Moment

As a form of therapy, I've just got to get this story out of my head...

So, I've got this adventure coming up this weekend where I'll be do some camping in Vermont (more to come on this, of course). Rather than fly up my gear, I had the brilliant idea of giving it to my buddy Greg who's driving up to Vermont. There was only one small detail - I had to get my crap over to Greg who works and lives about 30 - 45 minutes away in Maryland.

That may not sound like a big distance, but our schedules were just not matching up. Finally, I decided to bite the bullet and just drive my stuff over to him while he's at work. Sure, it would mean taking a chunk out of my work time, but it would be worth it. We agreed on a time and we were all set.

Now, normally I'd screw this up by leaving at say 11:35am, when our agreed upon time was 11:45am. I wouldn't do this intentionally, I'd just be trying to get that last thing done before I bolted.

The second way I'd mess this up is to get on the road and realize I don't exactly know how to get to his place (I do this, without fail, every time I go to the orthodontist - another reason to dislike braces!). The result of course is that I'd end up being late.

So, imagine my absolute joy when I pulled into his parking lot at 11:43am. Bam, I was perfect!

And then it hit me. Uh oh. Did I really? Oh crap, I might just have. Quick, check the trunk.

Yep, you guessed - I left the actual gear that I was going to drop off to him at home. Aaaarrrrrgggghhhhhhh!

All this effort, and I didn't accomplish the one thing I intended.

Now - on a good note, I did have a perfectly delightful lunch with Greg. And, I did get some time away from the computer where I could think through a couple of problems, and that can also be considered a good thing.

Yeah, this one's going to take a fair amount of effort to find the silver lining in.

Tuesday, August 11, 2009

Hack Of The Day: Creating a Windows Self-Extracting Zip File On Linux

One of our customers wanted to make it especially easy to handle a zip file download we were generating on the fly for him. On a hunch, I went looking for ways to generate self extracting ZIP files. The big catch being that I needed to be able to create them on the fly on a Linux box.

After a whole lot of poking I found two really useful articles:

In the first case, the very basic info-zip package is used (which you probably already have installed on your Linux box). The second option uses the 7-zip package.

Both systems use the same approach: take a small windows executable and append to it the actual zip file, and have Windows folks use that. The Windows executable at the start of the file will run first, no doubt seek to it's end, and then unpack the embedded zip file.

If you ask me, it's pure genius.

The 7-zip approach even gets slightly fancier, and embeds a configuration file between the binary and archive, which says what program to run.

A fancier solution is to take an installer like NSIS, and build it for Linux. Then, build up an installer package on the fly.

But for my purposes, the self extracting zip file should do the trick.

If nothing else, thinking through the whole appending-your-data-to-the-end-of-the-binary trick has been worth pondering. Come to think of it, perl actually made extensive use of this trick with their __END__ and __DATA__ keywords.

Monday, August 10, 2009

Palin is Back - And Palin'erer Than Ever!

I briefly lamented that Palin's resignation could mean good bye from the spotlight of politics, and how on a certain level I'd be disappointed.

But, baby, is she back - and better than ever!

The America I know and love is not one in which my parents or my baby with Down Syndrome will have to stand in front of Obama’s “death panel” so his bureaucrats can decide, based on a subjective judgment of their “level of productivity in society,” whether they are worthy of health care. Such a system is downright evil.

Oh, this is too classic.

I find that most politicians know where the The Line is, and know how to just get close enough to it that they'll stay on the right side of it, but give their supporters enough of a hint to eagerly cross it. This whole birther movement is a great example. Take Giuliani's comments for example:

"I've actually seen a birth certificate that kind of satisfies me that he was born in the United States," he said. "I don't get the issue. I don't know why they're pushing it as far as they are. ... To pick false issues like that hurts us more than it hurts the other side."

He's not saying Obama isn't a citizen. He's even saying he's seen a birth certificate, and heck, there's not really an issue here. But, still, he uses language "kind of satisfies me." This leaves the door wide open for his constituents to read this as: See, even Rudy doesn't think Obama's a citizen - he just can't come right out and say it.

This political maneuver fires up the base, but leaves the politician on the side of truth. Politicians across the the spectrum do this, not just Republicans.

But not Palin, she has no patience for this sort of tactic. As she did in the campaign, she's perfectly glad to repeat a bold face lie, as she's doing here (and she's the one telling folks quit making things up).

What "death panels" are we talking about - and why exactly are they in quotes? Is she quoting from some source? Same goes for “level of productivity in society” - the quotes imply that text is in the bill, but of course it isn't.

This tactic of bold face lying, shouldn't work. But, the amazing part is, it does. People honestly believe that Obama, and our system of checks and balances are capable of setting up a death panels - whatever that would even mean.

Both sides of the debate should be outraged by tactics like this. The Democrats for obvious reasons, and the Republicans because this makes their cause against the bill look like it's all manufactured lies, and of course it isn't. There are legitimate issues with this bill, and focusing on fakes ones no doubt takes away from the real issues.

As always - I'm split on activity like this. The part of me that sneaks a peak at the tabloids in the check out line at the supermarket, loves this. The part of me that thinks our country deserves serious debate about a serious issue is just plain annoyed.

Legg Mason Tennis Tournament - A Broiling Good Time

Shira and I made it to the Legg Mason Tennis Classic yesterday. The best description we can come up for it is surreal. Here we are, in this relatively small venue (7,500 people) witnessing two of the top players in tennis duke it out. Shira's a bigger fan of tennis than I, but even I could appreciate this.

It was a beautiful day to watch tennis, with the exception of the fact that it was brutally hot. In fact, they were calling for one of the hottest days all summer. These players are truly amazing athletes for not only putting in hours of running around on the court, but doing it in the excruciating heat.

We saw both the doubles and singles finals for the tournament. We managed to show up to watch Martin Damm and Robert Lindstedt warming up for their doubles match, so we decided to root for them. It was a good call, as they ended up winning the match.

For the singles round, we were naturally rooting for for Andy Roddick. Alas, he lost after 3 sets and a 8-6 tiebreaker. Shira wasn't pleased by this, but at least we got to watch some fantastic tennis.

Here are some photos from the day. Next year, we may just have to spend the extra cash to get covered seats. But even with some minor heat exhaustion and sun burn, it was definitely a show worth watching!


Here's Robert Lindstedt warming up - no wonder Shira likes watching men's tennis!

OK, one more shot of Robert for the ladies.

Us before we were totally fried from the sun:

Man it was a scorcher!

Game on! Damm and Lindstedt kick off a volley:

D'oh - stupid net always getting in the way:

Roddick pounding the ball home:

Del Porto about to launch a serve:

Roddick returns a volley:

Thanks to the power of the Wii, we were able to get in on the action:

Friday, August 07, 2009

A Mini-Hike at Turkey Run Park

The day was too nice to spend it sitting in front of a screen all day - so Shira and I played hooky for a few hours, and hit Turkey Run park. It's hard to believe this little gem is only a few miles outside of DC - it's awesome.

We took a steep trail from the first parking area down to the Heriage trail, which runs along the Potomac. We hiked about 1 mile out, and 1 mile back, making for a leisurely walk.

It's definitely worth checking it out if you're in the area. It helps if it's a perfect summer day, like today.

Our route:


View Turkey Run in a larger map