Understanding different forms of locations

The azimuthal map program keeps a log of the parameters submitted and whether the map generation succeeded or not. It does not store or track IP addresses or anything that could link requests to particular users unless you identify yourself in the title. Looking at the logs lets me see how people are using the tool and more importantly how I can improve it.

The location field is the one that seems to trip people up the most, and I have been working quite a bit to expand the range of inputs that will work for the location. For example, you can enter degrees, minutes, & seconds separated by spaces now with a N, S, E, or W to specify the latitude or longitude. You can also use unsigned doubles followed N, S, E, or W instead of using signed values.

Most recently, you can enter city names. For large cities, you may be able to enter just the name. For example, “Chicago”, “Paris”, and “London” resolve to “Chicago, IL”, “Paris, France”, and “London, England”. For smaller US cities, enter the name and the state. For smaller non-US cities, enter the city name and country. This approach only works when the spelling and punctuation match exactly.

ARRL’s International DX contest was cool

Despite having a rather modest rig at my QTH and limited operating time, I am an aspiring contester.  This past weekend’s ARRL International DX contest was very cool. I worked a lot of countries that I’ve never worked before. Here is my list of new entities:

  1. Hong Kong (already confirmed by LoTW)
  2. Norway (already confirmed by LoTW)
  3. Sweden (already confirmed by LoTW)
  4. Honduras
  5. Chile
  6. France
  7. St. Kitts & Nevis
  8. Germany
  9. Spain
  10. Aruba
  11. Costa Rica
  12. Finland
  13. Cape Verde
  14. Dominican Republic

This is a lot of new entities for me. I am glad that I am finally making it to Europe.

Azimuthal map does US cities now!

The azimuthal map form can now add labels for US cities. The database of latitude/longitude pairs for cities seems imprecise because some California cities are in the Pacific ocean. It might also mean that the coastal outlines are not precise enough.

If you notice a city out of place, please let me know. There are some errors in the database. For example, San Francisco was a few miles out to sea.

Update: I updated the list of cities to include ones from Alaska and Hawaii.

Why isn’t the map form working?

The Ruby script that process the map configuration information given in the map form is very particular about what information it will accept. For example, if you enter a Maidenhead grid as fn31 instead of FN31, the program will not produce a map because the first two letters are supposed to be upper case. Similarly, the title will be rejected if it has non-printable or non-ASCII characters.

I wrote the program to be very strict about checking its inputs to ensure that people cannot cause the program to generate a hostile PDF.  Rather than trying to identify and detect all the bad things a malicious person might enter to generate malicious output, I have instead tried to ensure that only safe characters are allowed in the input.

Why Ruby?

Ruby is wonderful.

Why do I use Ruby for ham related tools? First of all, Ruby is just a great language. To me, Ruby has the best balance of readability and concision. I’ve written in a lot of languages, and Ruby is the best of the lot unless performance is a big concern.

Ruby has the right libraries for the job. First, it’s a big web language, so it’s available from most internet hosting sites. It’s got a library to parse CGI arguments, so it can be configured from a web form. Ruby also has a PDF writer library that helps create PDF from scratch without any other tools. Generating PDF is convenient for everyone Windows, Mac, and Linux.