Hello all, I have an algorithm i would like to implement in an fpga. I have no idea of knowing how many times the 'while' loop should run.
But doing something like this seems to be illegal in verilog. Any ideas of how i can get around this? How could i implement a c-style loop in verilog?
I tried to make a simple example of this. I'me using Quartus2 Web edition for the synthesis.
integer V; integer X; always @(V) begin V = 1;
while( V ) begin V = V + 1; X = X + V;
if( X < 30 ) begin V = 0; end end end
Thanks!