Electronic – Can you actually break an FPGA by programming it wrong

fpga

Can you actually break an FPGA by programming it incorrectly?

I'm a software guy really. It's no secret that if your software is wrong, you could destroy all sorts of important data, and perhaps even crash the whole machine. But it's really difficult to physically damage a computer just by programming it.

(There are endless rumous of a Halt-And-Catch-Fire instruction, or being able to reflash the system firmware to brick the motherboard, or programming incorrect values into the graphics card to fry your monitor. But these all seem to be exactly that: rumours. And all about long-obsolete hardware. It seems really, really hard to break modern computer equipment with bad programming.)

With an FPGA, you are (at least nominally) wiring individual circuits together. It seems completely plausible that physical damage might occur in case of a mistake.

For example, you could write some VHDL requesting that two outputs get tied together. If they output different logic levels, I imagine that would probably fry something. (I would hope that your synthesis tool would scream at you to not do this… but I don't know if such tools actually implement that level of error checking.)

It also seems quite possible to accidentally pick the wrong model of FPGA in the synthesis tool, and thus ending up trying to program your chip with a bitstream intended for some totally different model. I don't know what that would do, but I suspect it would be "bad".

For that matter, you could definitely connect the FPGA chip to the rest of the circuit incorrectly. E.g., if you mess up the pin numbers, you might end up with the board trying to drive an I/O pin that the FPGA itself is also trying to drive. Do the I/O pins typically have any "protection" against such a mistake? Or will the chip just fry?

Best Answer

It also seems quite possible to accidentally pick the wrong model of FPGA in the synthesis tool, and thus ending up trying to program your chip with a bitstream intended for some totally different model.

Typically the programming software will query the part being programmed for its part number, and refuse to program in a bitstream meant for a different model of FPGA.

The part itself will also generally refuse to start up if programmed with a bitstream that isn't exactly the correct length (and it's very uncommon for bitstreams for different chips to be the same length).

you could definitely connect the FPGA chip to the rest of the circuit incorrectly. E.g., if you mess up the pin numbers, you might end up with the board trying to drive an I/O pin that the FPGA itself is also trying to drive.

This is the most likely way to damage an FPGA with wrong programming.

Another way could be to program a very resource intensive design and run it at a high frequency (so that a high power is consumed), and then run it on an FPGA without an adequate heat sink.

Do the I/O pins typically have any "protection" against such a mistake? Or will the chip just fry?

Output pins will "often" survive a short circuit condition for a few seconds or even minutes. But nothing is guaranteed.