Intel® Quartus® Prime Software
Intel® Quartus® Prime Design Software, Design Entry, Synthesis, Simulation, Verification, Timing Analysis, System Design (Platform Designer, formerly Qsys)
16596 Discussions

How would you create infinite simulation loop in modelsim using erilog/ vhdl

Altera_Forum
Honored Contributor II
2,350 Views

Any ideas, hints would be helpful.

0 Kudos
8 Replies
Altera_Forum
Honored Contributor II
1,085 Views

You could just post your homework assignment for us. :) 

 

You could create a task that contains your loop. Then just schedule the task to run at some predefined interval. 

 

Jake
0 Kudos
Altera_Forum
Honored Contributor II
1,085 Views

Hi Jakob, 

 

I wish this was only an assignment :)  

 

 

I do thank you though and if you do have any other suggestions please do let me know.  

 

 

thanks
0 Kudos
Altera_Forum
Honored Contributor II
1,085 Views

I presume you are aware of the $stop and $finish directives in verilog? 

 

Descriptions from the sutherland HDL reference: 

$finish; 

Finishes a simulation and exits the simulation process. 

$stop; 

Halts a simulation and enters an interactive debug mode. 

 

Jake
0 Kudos
Altera_Forum
Honored Contributor II
1,085 Views

thanks for your help..

0 Kudos
Altera_Forum
Honored Contributor II
1,085 Views

This should make modelsim get stuck in an infinite loop in VHDL: 

 

signal a : std_logic := '1'; signal b : std_logic := '0'; ... b <= a and not b;
0 Kudos
Altera_Forum
Honored Contributor II
1,085 Views

thanks tricky... did end up doing something like that. general question can anyone give me an example how do i make 2 always loops to be continuously switching between each other

0 Kudos
Altera_Forum
Honored Contributor II
1,085 Views

you can try  

... 

process 

begin 

...... 

loop 

wait until clk='1'; 

...... 

end loop; 

end process;
0 Kudos
Altera_Forum
Honored Contributor II
1,085 Views

Did I conceive a circuit under quartusII and do I want validated it by a file of data to elaborate by a program in C language, and to recover the exits as a file text, how to make?

0 Kudos
Reply