I was having problems using JTAG on the Spartan-3E FPGA.
Sometimes it would work, but not reliably, and most of the time it would not work. The JTAG waveforms looked good on the scope.
iMpact would complain that the ID number of the chip was wrong.
It was also very senditive to the cable used. I tried various flat cables with some limited success.
I am using this JTAG adapter (click image for link).
After lots of head scratching, here came the fix : remove the 3 capacitors shown below in the Trenz JTAG adapter. The purpose of those caps besides corrupting signal integrity is a mystery.

Result : now it works flawlessly.