I like the stick-a-wire-on-a-potentiometer-and-drag-it-on-the-ground method. Simple to implement and pretty cheap. Probably not as responsive as a visual sensor, but that would just take a bit of...