VHDL and using the 'report' Statement

Myles picture Myles · Jul 26, 2011 · Viewed 48.2k times · Source

I've been having some issues with some VHDL code I wrote (see my other question for details if you're curious: VHDL integer'image Returns "0"). I need some way to see what is happening to my variables. Everything I read seems to indicate that I should be able to use the 'report' statement to see some output, but nothing I've read tells me where I would see this output.

So my question is this:

I'm writing VHDL code and programming an Altera DE2 FPGA board... Can I use the report statement to get some output, and if so, how? Currently I'm using Altera's Quartus II software. I tried to install ModelSim, but the student edition does not seem to work on Windows 7 (I can't even get an installer to show up... running the setup just leaves a dangling process).

Thanks!

Answer

Philippe picture Philippe · Jul 26, 2011

The report statement prints its output to the console of your simulator. If you work with Altera, you probably want to the ModelSim version that they ship.

a := 5;
report "The value of 'a' is " & integer'image(a);

People also use wave traces to debug their code. But you also need your simulator for that.

You'll need to find a way to get ModelSim installed on your Windows 7.