I was trying to program in a new remote entry fob. The instructions involved finding the data port and shorting across two pins, then doing a few other things (turning the key on and off, pushing some buttons, sacrificing a chicken). The data port is under the dashboard, in a particularly awkward place. No matter what I did, I couldn't see it well enough to see which pin was Pin 1. I tried a flashlight and a hand mirror, but that was no help.
I went upstairs, grabbed a camera, and put it into macro mode. I took a few photos of the connector, then came back upstairs and fed them into photoshop so that I could zoom in and change the contrast if necessary. Voila! I could clearly see the pin numbering, and the rest was simple. (I used frozen chicken.)