Agribotix's GoPro Adventure

 

The Agribotix precision agriculture team has been using modified Canon S100s this growing season for almost all our UAV-based imaging.  While there are a lot of good things to say about the S100 (low cost, high resolution, pretty good optics come to mind), in general they have been the greatest source of difficulty in the field for Agribotix.  Here are our main gripes:

  • With the Event38 red-notch filter installed, the manual focus no longer works.  Autofocus on the S100 operates using a contrast detection algorithm, which just isn’t reliable for canopied-over “green-on-green” crops.
  • As is well documented on the official Canon website, the S100 is prone to a lens error when it gets hot (not that this ever happens when we are flying corn fields in Illinois in July…).  Sometimes the camera recovers when it cools but we’ve had to send a bunch back to Canon for $160 repairs.  Canon refuses to fix this self-admitted design flaw.
  • A retracting lens is just plain a bad idea for UAV use, especially in agriculture – both from a lens vibration standpoint and fragility.
  • Weight.  At 190g we’re carrying around a lot of stuff we don’t need.
  • CHDK just isn’t ready for prime time.  The “H” (i.e. hacker) aspect of it is all too apparent.

So what we need is not a full function camera like the S100 but a bone-simple rugged unit.  Our ideal camera would have only a fixed focus, fixed focal length lens, a sensor (5 Mpixels or greater), the glue to make it work together -- and nothing else.  It finally dawned on us that the GoPro is pretty darn close to ideal. 

With the waterproof housing removed, the GoPro is REALLY small.

With the waterproof housing removed, the GoPro is REALLY small.

The showstopper for the out-of-the-box GoPro is the silly fisheye lens.   I wrote a post a few months back about the Ribcage mod to the GoPro, which seemed like a good idea.  But it’s pretty expensive and is a major project to install.  However I recently discovered that GoPro uses a standard S-mount (aka M12) lens and that it’s removable.  So there’s no reason to use the Ribcage unless you want to use C-mount or larger lenses. 

S-mount (aka M12) lens fits the GoPro with little mods.

S-mount (aka M12) lens fits the GoPro with little mods.

Thus, we’ve started down the adventure of making GoPros work for our precision agriculture UAVs.  The first step is to get the lens out – and it’s not quite as easy as I made it sound above.  GoPro puts a bit of glue on the M12 threads so it’s a white-knuckle affair to unscrew the lens.   Check out some useful YouTube videos on this process before you make the plunge:   RageCams, Peau Productions, Ifti's Tech Corner.  But in the case of the Hero3+ Silver that I modified, the lens came out much easier than is shown in the videos.

I found a wide selection of M12 lenses at Peau Productions.  The ones they call “NightVision” do not have the IR-blocking filter installed, so that’s what you’ll need if you want an NDVI setup.  I first bought a 2.97mm focal length lens, which is amazingly wide angle but has no apparent fisheye.  However, Photoscan Pro is having a hard time stitching the images from it cleanly.  The image below is a zoomed section of what is, in reality, a straight road.  I have a 4.14mm lens on order from Peau that I hope will address the problem.  Or it could be that the calibration parameters from the Agisoft Lens program will solve the issues of the 2.97mm.  All my testing with lens calibration targets shows that the Peau Productions lenses are as good as the S100.

This road really isn't squiggly! 

This road really isn't squiggly! 

The final step is to get the Event38 filter installed in the GoPro camera.  And we have to credit dumb luck for this working out.  It takes some work to open up the GoPro to get access to the sensor element (the teardown guide in the Ribcage documentation will help with this step).  It’s little harder than getting to the sensor in the S100, but not by a lot.  The dumb luck is that the 8mm x 10mm Event38 filter fits perfectly into the GoPro lens holder as you can see in the photo.  A bit of CA glue in the corners tacks it down securely.

Event38 red-notch filter drops into the GoPro lens holder perfectly.

Event38 red-notch filter drops into the GoPro lens holder perfectly.

So, that’s about all it takes to turn a GoPro into a kickass NDVI drone camera.  In summary, here are the good things about the GoPro:

  • Small and light (46g without the battery)
  • Tough
  • Fixed focus
  • High resolution (10 Mpixel for the Hero3+ Silver)

And what’s not to like:

  • I can get S100s on eBay for around $180, but the Hero3+ Silver plus the Peau Productions lens is more than double that.  We’re working on a low-cost source for cameras – stay tuned.
  • The S100 has a GPS, which syncs the camera clock exactly to the flight controller clock.   Without the syncing we need to take a picture of the ground station screen with the GoPro and manually sync the photo EXIF metadata.  The syncing is required for geotagging the photos, and the manual step is a PITA.  We are working up a solution that; if it works out I’ll write a post on it soon.

Go ahead and Connect with Agribotix if you're interested in learning more about UAVs for precision agriculture, NDVI and other vegetation index image processing, or just want to ping us about fun projects like this one.