The adapter I’ve been using for my iPod in the car for years developed a short a few weeks ago and I haven’t been able to find a similar model to replace it yet, so I’ve been using an old Griffin FM transmitter instead. It’s not great and I frequently hit dead zones where there’s interference - either from a real radio station, another car transmitter, or just normal interference that overpowers the tiny iPod accessory.

I was driving through the mountains yesterday afternoon, enjoying what will probably be one of our last nice days (74 degrees!) for the year and at one point my transmitter became entirely useless. Apparently on the other side of a nearby mountain the frequency I’d been using without problem belonged to a real station that easily drowned out my tunes.

That got me thinking… The FCC divides up wireless spectrum for different purposes and usually tries to carve out sections for consumer goods where they’re unlikely to conflict with each other. Maybe there should be a similar area of the FM spectrum that is forbidden from use by radio stations and is reserved for personal use (like my iPod).

It’s unlikely that I’ll be able to convince the FCC to go this route (not to mention it wouldn’t help me for a decade or more anyway), so I looked at it from a different perspective: maybe there’s an area of the regular FM spectrum that just isn’t used all that frequently by radio stations that would be a “safe” zone for my iPod.

Thanks to the federal government’s “transparency” push, there’s more data available than ever before from public agencies. The FCC in particular publishes a crapload of data on their Reboot site. All radio stations have to file for a transmitter license with the FCC and one of the data exports provided is the entire FM license database. Great!

Well, not so great. In the zip file you download (from the Wireless Telecommunications Bureau’s list of Licensing Database Extracts) you get several files. The important one is fm.dbf. Uh oh, what is a .dbf file? dBase? Didn’t Borland dump that over a decade ago?1 Now I have to find a way to parse this. A quick Google shows a bunch of crappy products to convert dBase files to CSV or XLS format, but there’s no way I’m going to pay to convert a single file.

Fortunately, there’s a dBase extension for PHP! A quick port install php5-dbase on my Mac gets me the tools I need to parse out the file. A little reading in the PHP manual and a few lines of code later and I’ve got a working script to parse out the data and dump it into a TSV file. Now I can check the data in Excel and do any manipulation I want.

Being a programmer, of course, I opted to write another script to parse the TSV file I’d created and see how many stations there are using each FM frequency.

A quick function to parse a TSV file into an array2 and two loops later and I’ve got an array of frequencies to the number of stations using it.

I’d been using 88.1 FM, the lowest frequency my Griffin transmitter supports, because it was easy to get to on the radio and seemed pretty clear. Turns out that was a bad choice… 88.1 FM is the #1 most popular frequency in the US. According to the number of registered stations I’d stand the best chance nation-wide picking 99.73.

My next time waster might involve looking more specifically at the area I live in for the least-used frequencies. The FCC data provides a city and state as well as latitude and longitude for each station, so there are two ways to easily pick out nearby stations. Plotting all the stations on a map along with their possible coverage area would also be really cool.

I’ve put both scripts up in a GitHub repo for the project along with the results of my most-used frequencies script. If you’re really lazy you can also grab the TSV format file I generated from the original dBase version, even though it’ll be outdated immediately.

  1. They did, in 1999, by the way. 
  2. I opted for TSV simply because some fields can contain a comma which makes using a CSV file a pain to parse. 
  3. The least-used frequency is actually 87.9, with only 2 licensees, but my transmitter doesn’t drop into the 87’s. 
Originally published and updated .