It may seem hard to believe now, but the idea of combining pirates and voodoo in fiction was new then -- incredibly, no one had done that, so far as I, or anyone I spoke to, knew.
So I was amazed that this obvious combination had somehow eluded everyone for so long, and tried to think of some similarly-obvious connection that I could base a story on.
I didn't actually find one, but that did get me thinking about similar ideas that had been used in very different contexts, and I hit on sand-ships. I knew of three very different stories involving sail-powered vessels operating on land: Ray Bradbury's The Martian Chronicles, Lord Dunsany's "A Story of Land and Sea," and the story of Windwagon Smith. I realized I could combine these, and maybe get a pretty cool story out of it.
So I did -- but there were complications. Thomas "Windwagon" Smith was a real person who had been dead for a century or so, and "A Story of Land and Sea" was in the public domain, so I could do anything I wanted with them, but The Martian Chronicles was still very much in copyright.
I was caught up in writing the story, though, so I put that aside for later. Instead of worrying about it I spent almost a week researching "Windwagon" Smith -- mostly, but not entirely, at the local library, as the World Wide Web didn't exist yet. I got some assistance from my mother in Massachusetts, as well. I watched the Disney cartoon "The Saga of Windwagon Smith," read at least one children's book about him, and even managed to dig up a copy of one of the original 1854 newspaper accounts of his failed demonstration for his investors. (The reporter played it for laughs, correctly pointing out the biggest flaw in the whole idea -- the prevailing winds blow the wrong direction. You can't tack a ship into the wind on land the way you can at sea.)
Somewhere around the fifth or sixth day I realized I was being stupid, doing all this research for a short story, one that I might not even be able to sell, should Mr. Bradbury not cooperate. By that point, though, it was too late to turn back. I finished the story, and sent a copy to Mr. Bradbury, asking his permission.
Then I forgot about it for a couple of weeks, until a blue envelope arrived in the mail, which turned out to be a brief, handwritten letter from Ray Bradbury, giving me permission to do as I pleased with the story. It was the only legal document I've ever seen handwritten in silver ink on blue paper.
With that permission in hand I sent the story to Gardner Dozois at Asimov's, he bought it, and there you go.
The story went on to win the Asimov's Readers' Award, and to be reprinted and translated many times. It got adapted to comic-book form in Eclipse's Orbit, and recorded as an audiobook. It turns out that week of research wasn't a waste of time after all.
If you haven't read and would like to, it's included in The Final Folly of Captain Dancy and Other Pseudo-Historical Fantasies, from FoxAcre Press.
Oh -- I should probably mention that the ending implies the possibility of a sequel. In fact, I plotted one, sort of, but never wrote it. "A Yankee Circus on Mars" (the title comes from the first show at the old New York Hippodrome) would have been a sequel to both "Windwagon Smith and the Martians," and "One Million Lightbulbs." But I never got around to writing it, and no longer remember how I was going to end it.
That's it; here's your list of handy exits: