Forum Discussion
Altera_Forum
Honored Contributor
13 years agoIf anyone is searching for the answer, here is the link to the best answer
electronicspoint.com/calling-modules-always-block-verilog-t22145.html ( I cant post the link) In case if the link is not working, instantiate the calling module outside the 'always' block, and set the register values inside the always block. For example, I want to call this module in the always block, for that I can do the following ram_dp framebuffer1 (.CLK(CLOCK_50), .WE(we), .read_address(h_count_reg*800+v_count_reg), .write_address(h_count_reg*800+v_count_reg), .input_data(1'b1)//, .output_data(ram_dataout) ); inside the always block , set the value of 'we' , its working for me. Thanks.:evil: