gphoto2 is a command line app, so it can probably be made to run on the N900 quite easily. As for a USB-A female-to-female adapter, you could make your own if you want to be really cheap. I just took a double port of a USB1.1 hub I had bought from the pound shop and soldered the pins together, though this was more due to me being too impatient to wait for an adapter to be delivered when I wanted to try out USB hostmode on my N900, I do intend to buy myself a proper micro USB host cable sometime.