ArcGIS Authorization Error: 7174

When installing an evaluation copy of ArcGIS Desktop 10, you may receive an error message during authorization saying something like “7174: Authorization request for EVA123456 cannot be completed.”  Trial and error suggests that this error is caused by a conflict with a previously authorized installation using a different evaluation code.  Even though you may have uninstalled your previous evaluation software, and the installer detected no conflicts, there may still be flags in the registry referring to the previous installation.  This is ostensibly to prevent you from coasting forever with free evaluation software.  After evaluating an ESRI product, you should consider purchasing a long-term license.

However, students who switch from 60-day to one-year evaluation licenses cannot be faulted for wanting to do their homework.  Unfortunately, the one sure way to clear this error is to reinstall Windows from scratch.

Capturing the Quads

One of the most recognizable and beloved map products of all time is the USGS 7.5′ quadrangle topographic map, commonly known as a ‘quad’.  These maps have been available to buy in paper format for many years, and are considered a definitive reference by backcountry users, such as hikers, campers, and fishing enthusiasts.  These maps are also available as PDFs, and can be downloaded from the USGS at:

To download a map, first navigate to the area of interest using the Google Maps applet embedded in the page.  Then, click the radio button near where it says “MARK POINTS”.  Click anywhere on the map to mark a point.  Then click on the marker to bring up a dialogue box, showing which products are available for download.  Usually, you will see two 7.5×7.5 products: one is aerial imagery, dated 2011 and usually over 25MB.  The other is the classic quad, generally dated from the 70s or 80s, and has a size closer to 15MB.  The primary exception is for areas near the coast, where quads containing very little land are combined with their neighbors to make a 7.5×15 product – but you can still tell the imagery from the quads by the date and file size.

The download will be a zip file, which you can unpack and open in your favorite PDF reader, and print at your convenience.  The quality of the digital image causes jaggies to appear at almost all scales, but the maps are still readable.  I find that I can see fairly clearly at up to 150% zoom.

From here, you can download the TerraGo Toolbar, which allows you to measure and mark your GeoPDFs from within Adobe Acrobat Reader.  You can also use Global Mapper to convert your GeoPDFs into GeoTIFFs, which can then be imported into a GIS as a raster image.

Cartography for the Web

“Cartographic Design for Web Maps” is a new blog post from the ESRI Mapping Center. Written by Aileen Buckley, it is a fairly good primer on the principles of cartographic design. Of particular interest was the visual efficiency chart. On a related note, it’s interesting to note that we’ve supposedly given up on the idea of web-safe colors. Personally, I’d remain cautious when doing color design for the web – not everyone has a 17 inch monitor or a cutting-edge graphics card. For the most part, though, if it looks good on your screen, it will look good on your audience’s screens.

Bringing your Garmin GPS to Linux: Part 2

In Part 1 of this tutorial, I wrote about getting Linux to recognize and manage your Garmin GPS unit.  Now that everything is set up, we can begin to explore how to make use of the GPS.

Most of the work behind the scenes is made possible by the garmin_gps module, which is included by default in 2.6.x kernels.  This module acts as a ‘driver’ for the GPS.  You can verify its existence by executing the following command:
lsmod | grep garmin

One of the neat things you can do is have Linux read the position information from your GPS.  This is accomplished by gpsd, a background service which passes position information from the device to any program that can read it.  One such program is TangoGPS, which will display your current position overlaid over a basemap.  The basemap is constructed from tiles downloaded over the internet from a web mapping service (WMS) such as Google or OpenStreetMap.  With an internet connection, you can turn your Linux computer into a real-time navigation device.  Obviously, this has limited practical uses – but it is fun to play with.

A better use of your GPS is to collect position information in the field, either as tracks or points, and then use them on the computer.  Unfortunately, the garmin_gps module doesn’t really help with this.  There is a program called gpsbabel which will allow you to read and write from your GPS, but it is blocked by the garmin_gps module.  In order to get gpsbabel working we have to remove the module from the kernel, using this command:
modprobe -r garmin_gps

This only works temporarily, though – the module will be reloaded the next time you restart your computer.  To prevent this, you need to blacklist the module.  Add the following two lines to the end of /etc/modprobe.d/blacklist.conf:
# prevent garmin_gps from being loaded
blacklist garmin_gps

Once the module has been unloaded, gpsbabel should automatically take over the management of your GPS device.  This allows you to use a number of wonderful graphical GIS management programs, such as QLandkarte GT and Viking.  These programs can be used to transfer maps and data to and from your device, and are functionally similar to the proprietary Windows software provided by Garmin.

One small problem – while gpsbabel is managing your device, gpsd won’t work.  Fortunately, if you want to use it again, just reinsert the module by running the following command:
modprobe garmin_gps

If you prefer to return the module permanently to the kernel, simply comment out the last line of the blacklist.conf file like so:
# prevent garmin_gps from being loaded
# blacklist garmin_gps

Hopefully one of these solutions will help you on your way to happy GPSing.

(tested on Fedora 14, results on other distributions may vary slightly)

Bringing your Garmin GPS to Linux: Part 1

Interacting with your hiking/personal Garmin GPS unit in Linux can be simple and rewarding.  However, getting started takes a lot of work behind the scenes.  This tutorial requires you to execute terminal commands and modify read-only files, so it is for intermediate to expert users only.  Before beginning, make sure that the following packages are installed: gpsd, gpsbabel, and garmindev.

The first thing to do is connect your GPS via USB, and make sure that Linux has recognized your GPS.  The easiest way to do that is to execute the following command:

This command will show a list of system messages.  The last few on the list should be related to the connection of your GPS device.  My Garmin, an eTrex Venture HC, gives the following messages, indicating that it is connected to /dev/ttyUSB0:
[30206.209794] garmin_gps: v0.33:garmin gps driver
[30282.227125] usb 2-2: new full speed USB device using uhci_hcd and address 3
[30282.357447] usb 2-2: New USB device found, idVendor=091e, idProduct=0003
[30282.357455] usb 2-2: New USB device strings: Mfr=0, Product=0, SerialNumber=0
[30282.364664] garmin_gps 2-2:1.0: Garmin GPS usb/tty converter detected
[30282.365055] usb 2-2: Garmin GPS usb/tty converter now attached to ttyUSB0

At this point, the GPS should be up and running.  Unfortunately, you don’t have permission yet to interact with the GPS.  So the next step is to set up device permissions.  Create a file in /etc/udev/rules.d called 51-garmin.rules which contains the following line:
SYSFS{idVendor}==”091e”, SYSFS{idProduct}==”0003″, MODE=”666″

Now disconnect your GPS device and run:
udevadm control –reload-rules

(that’s a double dash before reload, not an emdash – sorry for any confusion)

The next time you connect your GPS, it should have the correct permissions, allowing you to interface with the GPS.

Coming up in Part 2: enabling and disabling the Garmin kernel driver.

(tested on Fedora 14, results on other distros may vary slightly)

Cartography: Bing Maps

Normally, I’m not a fan of Microsoft’s graphic design work. Their UI design, especially in Windows, is barely passable, compared to the innovative work in Apple’s OS X and the KDE project. It seems reasonable that their mapping UI would be equally horrid, and that, along with the ubiquity of Google Maps, has relegated Bing Maps to second-tier status. However, I suggest that everyone give Bing Maps a second chance, because their cartography is outstanding.

One thing I love about Bing Maps is the color scheme. I prefer the look of their blue roads and bluish-gray backgrounds to the Google standard of yellow roads and brownish-gray backgrounds. Another feature I appreciate is the heavy street casing. Casings are the outlines you can see along the edges of roadways, which help them stand out from the background. The casings on Google Maps are so light that they’re almost invisible. But Bing uses thick casings, which really make the roads pop. Bing’s marker symbol is also easier to see. Its warm orange color is easy to see on the largely blue map, but the value is complementary to the blue palette, making the contrast inviting, rather than stark. Google’s well-known call-out marker, which is a dark salmon pink, doesn’t seem to have an obvious color relationship to the rest of the map.

Google’s overall map design seems to be related to their colorful logo, in which every hue gets a turn.  This makes for some fun-looking maps.  Microsoft, on the other hand, has gone with a more limited palette, anchored by a safe bluish-gray, which makes for a tighter looking theme.  I think both are easy to see and highly usable.  And at this point in the game, there’s no reason to think that the underlying map data is any more accurate on one service than the other.  So for me, it really comes down to what looks nicest – and right now, that’s Bing.

Recently, Bing has received a major cosmetic upgrade, and it is better than ever.  To read more about what’s new, check out this gorgeous e-publication:

if Python

In some ways, Python is a very user-friendly language.  But it can be very finicky about indentation.  Instead of relying on white space and parentheses to impart structure, it uses exacting syntax.  To an inexperienced programmer, this is not a problem – in fact, it makes writing scripts very easy to learn.  Experienced programmers, on the other hand, might have a hard time getting used to Python’s syntax, which is quite different from other languages.

A prime example can be found in the if-then-else element.  Here is a short example in Python:

if x < 5:
   print("x is less than 5")
elif x > 5:
   print("x is greater than 5")
   print("x equals 5")

Notice the use of colons and indentation to show structure.  Now take a look at this example from JavaScript:

if (x < 5) {
   document.write("x is less than 5");
else if (x > 5) {
   document.write("x is greater than 5");
else {
   document.write("x equals 5");

In JavaScript, curly braces are used to separate control structure, and semicolons are used to terminate individual statements.  Even though I have used an indentation style similar to the Python example, it’s important to note that I could have skipped the indentation altogether – the JavaScript interpreter knows to ignore all white space.

In summary, it may take you awhile to develop new habits when programming in Python.  And it may temporarily lead to bad habits in other languages.  But the benefits of learning Python far outweigh the cost.

break if try

The Python programming language, which has become the standard for scripting in ArcGIS 10.x, is quite versatile, and has a very natural language style.  One specific difference from earlier languages (like C) is that variables don’t have to be declared or cast.  Instead, they can be declared and assigned in the same statement.  Variables have to start with either a letter or an underscore, but can otherwise contain any characters except a dash.  However, there are some reserved words which cannot be used as variable names.  Here’s a list of those words:

True, False, None, and, as, assert, break, class, continue, def, del, elif,
else, except, finally, for, from, global, if, import, in, is, lambda,
nonlocal, not, or, pass, raise, return, try, while, with, yield

I’ve started studying Python recently, so it will be the focus of the next few blog posts.  Stay tuned for more useful information.


British GIS site is currently hosting a poll about GIS data formats.  Not too many people have voted yet, but a clear trend is already emerging.  The data suggests that PostGIS has been gaining a lot of ground, eclipsing other popular proprietary data formats.  Here’s the current breakdown:

PostgreSQL/PostGIS - 17 votes, 65.4%
Proprietary Database (ArcSDE, SQL Server, Oracle Spatial) - 5 votes, 19.2%
PBBI MapInfo Tab File - 2 votes, 7.7%
ESRI Shapefile - 1 vote, 3.8%
MySQL - 1 vote, 3.8%
Google Earth KML - 0 votes
Something else - 0 votes

(data current as of 12 July 2011, 18:56 GMT)

Demonstrating the MapPress Plug-in

Adding a Google map to your website isn’t terribly difficult, as long as you’ve read some documentation and understand a little JavaScript.  But when it comes to displaying maps in a blog or CMS, adding custom JavaScript via a WYSIWYG interface can be tricky.  This site is powered by the WordPress CMS, and I’m not totally sure where to begin adding Google or OpenLayers code, without adding unnecessary code to every post.

Fortunately, there are plug-ins available for everything these days.  MapPress is a plug-in for WordPress that can add a Google map to a blog post.  With a single click, it is possible to add a great-looking map and some custom locations.  Further customization allows even greater control over the map, and there’s even a Pro version available.

MapPress website:

WordPress website: