Using Google Maps to produce usable, printable maps

This is a follow-up to my Making maps from GIS data with Inkscape post. After playing around with Inkscape for quite a while, and coming up with the dismal results seen in that post, I decided there has to be an easier way. A little Googling turned up this video tutorial on how to print large scale maps from Google Maps. It turns out that the Google Maps API will honor almost any pixel resolution that it’s passed. The Screengrab add-on for Firefox has the wonderful capability of being able to capture a screengrab of page content, at actual resolution, regardless of screen resolution. So load up a 5000×5000 pixel Google Map, use the Screengrab addon, and end up with a full 5000×5000 pixel image file.

After testing this a bit, I decided to go the Google Maps route. This also has a lot of other added bonuses – I can store my overlay data in simple XML files, add and remove layers on-the-fly, and also make it available online (and, theoretically, to any Google Maps-equipped device used by responders). This even opens up the possibility of using paper maps as a last resort, and providing the Fire Department with live hydrant maps on GPS-enabled handheld devices and phones.

The quirks, however, may need some serious photoshopping (err, rather, gimping) to fix:

  1. With all of the background color, how will this look when printed?
  2. How do I make the town borders easily defined? It would be a lot of raster editing to remove the background color of areas outside of town.
  3. How do I overlay a grid for a street name index?

The first step was to setup a large Google Map to develop with. I used PHP and Monte Ohrt’s GoogleMapAPI PHP wrapper class. It was simple enough to setup a big (3300x5100px) map, zoom out in Firefox, and start adding some stuff. My examples and development pages, if you want to take a peek at the code, are here.

The first step was to draw a polygon for the outline of the town. I found some very detailed information on how to get zip code boundary lines on Matt Cutts’ blog. Apparently, he’s a Google software engineer, heading up their webspam team. I grabbed the files from the Census, as described, and came up with the boundary for my zip code looking like:

        60      -0.741427638843858E+02       0.409963180802469E+02
      -0.741375870000000E+02       0.410075970000000E+02
      -0.741308870000000E+02       0.410061970000000E+02
      -0.741308870000000E+02       0.410061970000000E+02
      -0.741307260000000E+02       0.410032600000000E+02
      -0.741326870000000E+02       0.409955970000000E+02
      -0.741278870000000E+02       0.409943970000000E+02
      -0.741280870000000E+02       0.409938970000000E+02
      -0.741327870000000E+02       0.409853970000000E+02
      -0.741352870000000E+02       0.409830970000000E+02
      -0.741369600000000E+02       0.409818620000000E+02
      -0.741410520000000E+02       0.409821940000000E+02
      -0.741412870000000E+02       0.409826970000000E+02
      -0.741412870000000E+02       0.409826970000000E+02
      -0.741417870000000E+02       0.409847970000000E+02
      -0.741427870000000E+02       0.409863970000000E+02
      -0.741482870000000E+02       0.409868970000000E+02
      -0.741536880000000E+02       0.409899970000000E+02
      -0.741510880000000E+02       0.409929970000000E+02
      -0.741531880000000E+02       0.409965970000000E+02
      -0.741571880000000E+02       0.409988970000000E+02
      -0.741557880000000E+02       0.410013970000000E+02
      -0.741461870000000E+02       0.410018970000000E+02
      -0.741400870000000E+02       0.410065970000000E+02
 
      -0.741375870000000E+02       0.410075970000000E+02
END

As per Matt’s instructions, I stripped off the first and last lines, converted everything to normal decimal notation, and built it into a PHP array:

$MP_boundary = array();
$MP_boundary[] = array(-74.137587, 41.007597);
$MP_boundary[] = array(-74.130887, 41.006197);
$MP_boundary[] = array(-74.130887, 41.006197);
$MP_boundary[] = array(-74.130726, 41.003260);
$MP_boundary[] = array(-74.132687, 40.995597);
$MP_boundary[] = array(-74.127887, 40.994397);
$MP_boundary[] = array(-74.128087, 40.993897);
$MP_boundary[] = array(-74.132787, 40.985397);
$MP_boundary[] = array(-74.135287, 40.983097);
$MP_boundary[] = array(-74.136960, 40.981862);
$MP_boundary[] = array(-74.141052, 40.982194);
$MP_boundary[] = array(-74.141287, 40.982697);
$MP_boundary[] = array(-74.141287, 40.982697);
$MP_boundary[] = array(-74.141787, 40.984797);
$MP_boundary[] = array(-74.142787, 40.986397);
$MP_boundary[] = array(-74.148287, 40.986897);
$MP_boundary[] = array(-74.153688, 40.989997);
$MP_boundary[] = array(-74.151088, 40.992997);
$MP_boundary[] = array(-74.153188, 40.996597);
$MP_boundary[] = array(-74.157188, 40.998897);
$MP_boundary[] = array(-74.155788, 41.001397);
$MP_boundary[] = array(-74.146187, 41.001897);
$MP_boundary[] = array(-74.140087, 41.006597);
$MP_boundary[] = array(-74.137587, 41.007597);

Though this data doesn’t seem exactly 100% accurate (at least by my knowledge of the town, and every map I can find) it’s quite close and a very good start.

I’ll update later this week when I have some more done…

Update on my F-250 – Icom mobile, antennas, strobes

I’ve done a bit of work on my truck since my last update, and also have some new photos. The work done includes:

  • Added 4 strobes head to rear of truck, with strobe box in NEMA enclosure in bed.
  • Icom F5061 (VHF 50W) mobile radio in console
  • Three antenna mounts and antennae on roof – WiFi antenna, VHF mobile antenna and wideband scanner antenna. The installation and wiring was done by Ken’s Auto Electric of Midland Park, NJ (Ken is a great guy, and prices very reasonably).

Click photos for larger version.

truck photo

Looking good after a wash and detail…

truck photo

Another photo after the wash (before antenna installation)

truck photo

Front lighting job finished.

truck photo

Direct frontal view (before antennae). The Dual Avenger is barely visible behind the Super Duty graphic at the top of the windshield, but shows through very clearly when lit.

truck photo

Running board mounted LIN4′s.

truck photo

Rear license plate mounted LIN3s and rear strobes.

truck photo

Closeup of rear LIN3s on license plate bracket.

truck photo

Icom F5061 mounted in center console, wired to center antenna.

truck photo

Video of rear lights (LIN3s and strobes) during the day. Quicktime MOV, 20 seconds, 26 MB. download/view video.

truck photo

Video of truck lit at night, shot from all sides. 24 seconds, Quicktime MOV, 29 Mb. download/view video.

truck photo
truck photo
truck photo

Antenna installation by Ken’s Auto Electric. Front to rear:

  1. L-Com HG2405U-NMO 2.4GHz 5dBi WiFi antenna for future laptop.
  2. Antenex QW152B 152-162MHz 1/4 wave unity gain VHF antenna hooked up to Icom mobile.
  3. Antenex ABSCANC 150/450/800 MHz scanner antenna.

Truck Wiring and Lighting – Part I

As mentioned in my Custom Truck Console post, since my truck was stolen and now recovered (with all of the emergency equipment stripped out – weird) I’ve got to start from scratch. Since I finished the console, I’ve started work on redoing the lighting. The first grueling step was to check continuity of the existing wiring (what was left of it), strip out everything that didn’t work, and rehab what did. Then I did a few pulls, mainly a giant pull from the console to under the hood of six 16-ga wires and three 12-ga, along with a massive run of 6-ga welding cable direct from the battery (with a circuit breaker) to the console.

There’s a thread covering this install over at elightbars.org as well as a thread on the previous (original) installation.

This is part 1 of (hopefully only) 2. The list of what’s installed so far is:

  • Custom console.
  • Galls SE082 switch box – 3-position slider, 5 on/off rocker switches and one on-off-(on) rocker switch.
  • Radio Shack Pro-433 scanner, hopefully to be replaced by a Icom F5061.
  • B/B Whelen Dual Avenger above rearview mirror.
  • Unitrol 80K air horn (siren wires not connected)
  • 2x Sirennet 100W speakers mounted in front bumper.
  • 2x B/B Whelen LIN4′s on 10-75 Lighting front license plate bracket.

The console with equipment mounted in it:
console

Dual Avenger (B/B) on headliner bracket above rearview mirror – it just fits:
dual avenger on headliner bracket

Avenger from the outside:
avenger from the outside
avenger from the outside, lit

10-75 Intersection Bracket behind front license plate. B/B LIN4′s:
10-75 intersection bracket

SirenNet 100W speakers behind front bumper:
speakers in front bumper

Coming next:

  • 4x (!!!) blue Whelen 500 Linear Super LED’s in front grill, mounted with chrome flanges.
  • B/B LIN4′s on front running board mounts.
  • Blue LIN3′s on rear license plate bracket.
  • Some sort of lights in the rear window – if I can afford it, blue/amber Whelen 400 Linear’s (6-over-6) independently switched.
  • Icom F5061 VHF mobile.
  • VHF antenna, either roof mount or mounted in a stake pocket.

Custom truck console

I’ll keep this post relatively to the point (the original full story is on eLightbars.org here and here). My 2006 Ford F-250 CC XLT was stolen in September, 2008. It was recovered about a month later, after Geico said they’d pay out, and after I’d bought another vehicle. Anyway, it came back from the body shop about 2 months later, and it was time to begin customizing it again. The main parts of the project were wiring and installation and building a custom console…

My main inspiration was some of the custom consoles done by places like Odyssey, though I wanted something carpeted (hopefully a close match to the factory interior). The main idea I was working off of was this one from Odyssey:

Odyssey Excursion console

The general idea was to have a replacement for the factory console which would allow mounting of a radio, emergency lighting controls, and a few other things while not sacrificing storage space. The specific requirements that I came up with included:

  • Mount over the transmission hump more or less where the factory console is, forward to the dash.
  • Allow access to the pull-out cupholders in the dash and not impede access to any controls.
  • Fasten to the floor using only the four factory console bolts.
  • Allow mounting of at least one radio, one switch box, GPS and scanner.
  • Radio and switch box should be mounted using the Jotto Desk faceplates that I had from the CVPI console.
  • The real clincher that prevented me from using a stock console: Have a large storage compartment comparable to the factory console.
  • Provide a set of rear cupholders.

I spent some time over the course of three days or so measuring the console area of the truck and drawing out my initial plan in CAD (specifically the demo version of QCAD for Linux – regrettably not Free software). Once I had the plans drawn up and was satisfied that the angles and measurements were within acceptable tolerance, I made a full-scale prototype out of foam core board. With a little shaving of the corners, I managed to get a relatively good form and transferred it to ½" cabinet-grade luan plywood. It was a bit difficult with only a jigsaw, but worked out relatively well. While I can’t seem to find any pictures of the foam core, here are some of the wood form being assembled and the test fit in the truck:
first assembly and test of console
first assembly and test of console
first assembly and test of console
I’d originally been a bit worried about the structural integrity, but I found that by clamping the corners, pre-drilling and securing them with aggressive wood screws at approximately 1 screw per 1.5 inches along the joints, the plywood held together fine.

After testing the fit and checking that the four factory bolt holes lined up correctly (which they did, and also held the console quite securely), I pulled it back out and started the process of carpeting it. I bought 2 yards (76 x 72 inch) of color #8078 “Dark Grey/Quartz” plush cut pile automotive carpet from StockInteriors.com, for about $80 with shipping. It turns out that the color isn’t an exact match to the factory carpet (I got 6 sample squares from them and this was the closest color) but it’s a good medium between the carpet and upholstery.

Planning for how to cover this wooden behemoth with carpet took quite a few hours, and short of making it into a week-long job of sewing, I decided to wrap the sides and back with one piece, folded over on the bottom and top edges of the storage box, then use separate pieces for the top of the console and the front (which would be adjacent to the dash and mostly hidden from view). I started off with a plan to use 3M Super 90 spray adhesive, on the advice of an ELB member. Unfortunately, I could only find Super 77.

Prior to carpeting, I had to get the equipment mounting openings down to about 8.5" for the 8.75" Jotto faceplates. I cut some excess luan plywood down into 2" wide strips and then cut them to length for the openings, sandwiching about three together with Liquid Nails and then mounted them vertically on the sides of the console.

Carpeting the console at 2 AM probably wasn’t the best idea. I looked at how the cut edges of the carpet would meet and the corners, and decided I’d need some sort of edge molding to make it look good – preferably black powder coated aluminum, somewhere around ½" legs. As such, I decided to forgo most of the glue and stapled the carpet at the edges, planning to cover it with molding. Ok, I lose a few points for that one. The last thing to go on was the carpet on the front and top, which I glued with Super 77 and also stapled on the front (where it can’t be seen). I cut X-shapes in the mounting areas and folded the carpet down, stapling it to the inside of the console, and cut a slit in the front for wiring. The glue didn’t seem to hold on the narrow parts of the top/mounting area, but once faceplates were screwed in it was fine. The faceplates are just held in with screws into the vertical wood strips placed on the sides of the opening.

Top view of the console, mounted in place, with the unfinished storage box.
top view of console

Equipment mounting area:
console equipment mounting area

View from the driver’s seat:
view from drivers seat

Factory cupholders extended with just enough clearance to work:
factory cupholders open, barely

Staples around the edges, intended to be covered with molding. They’re really not that visible unless you make a point of looking at them (given their placement). Red handle is a 100A cutoff for the main battery lead, with a removable handle.
staples around edges and battery cutoff switch

The weekend after console fabrication, I started wiring. Here’s the relevant parts involving the console.

Semi-finished console with equipment mounted. Front-to back, RAM magnet mount for GPS, Radio Shack Pro-433, Galls SE082, nifty Jotto storage tray.
equipment in mounted position

Wire routing in loom from the console to under the dash
main wiring runs

Rear of console – Jotto cupholder and charger for Streamlight Stinger 75014
rear of console

Still to be done:

  • Most of the wiring and installation.
  • Lining the storage box with something, probably toolbox drawer liner.
  • Making a cover/lid for the storage box.

Possible Downtime this weekend

Tropical Storm Hanna is expected to reach the New Jersey area on Saturday, September 6, 2008. The latest predictions as of 20:00 September 4th call for winds from 30-60 MPH and rainfall possibly in excess of 5 inches, at a rate of 1-1.5 inches per hour (as per the Bergen County Office of Emergency Management).

In light of this, please be advised that JasonAntman.com may experience some unscheduled downtime – mainly due to the fact that my internet connection (Verizon FiOS fiber, right now) is run with suspended pole-to-pole cables. If this does happen (and power is still available) I’ll make an effort to use the downtime as best as possible.