wtr
Full Member level 5
Hello all,
I'm curious about how I can do the following in verilog
I'm aware of parameters. I want to code in verilog 2001 or 2005.
Can I do the following
The reason I'm having doubts is because the N is declared after the use.
The internet just seems to have all the old stuff anyone got a good tutorial for 2001 or 2005 syntax.
Then when instantiated in the module I expect something like the following
Being a vhdl guy it hurts to not instantiate as
module_name module_instance #param #ports
Thanks
Wes
I'm curious about how I can do the following in verilog
Code VHDL - [expand] 1 2 3 4 5 6 entity PARITY is generic (N : integer); port (A : in std_ulogic_vector (N-1 downto 0); ODD : out std_ulogic); end PARITY;
I'm aware of parameters. I want to code in verilog 2001 or 2005.
Can I do the following
Code Verilog - [expand] 1 2 3 4 5 module parity ( input [N-1:0] A, output ODD ); parameter integer N=8
The reason I'm having doubts is because the N is declared after the use.
The internet just seems to have all the old stuff anyone got a good tutorial for 2001 or 2005 syntax.
Then when instantiated in the module I expect something like the following
Code Verilog - [expand] 1 2 3 4 parity #(.N(16)) UUT( .A(my_in_sig), .ODD(my_out_sig) );
Being a vhdl guy it hurts to not instantiate as
module_name module_instance #param #ports
Thanks
Wes