vgencomp component declaration
vgencomp generates a component declaration according to these rules:
Generic clause
A generic clause is generated if the module has parameters. A corresponding generic is defined for each parameter that has an initial value that does not depend on any other parameters.
The generic type is determined by the parameter's initial value as follows:
Parameter value Generic type integer integer real real string literal stringThe default value of the generic is the same as the parameter's initial value.
Examples
Verilog parameter VHDL generic parameter p1 = 1 - 3; p1 : integer := -2; parameter p2 = 3.0; p2 : real := 3.000000; parameter p3 = "Hello"; p3 : string := "Hello";Port clause
A port clause is generated if the module has ports. A corresponding VHDL port is defined for each named Verilog port.
You can set the VHDL port type to bit, std_logic, or vl_logic. If the Verilog port has a range, then the VHDL port type is bit_vector, std_logic_vector, or vl_logic_vector. If the range does not depend on parameters, then the vector type will be constrained accordingly, otherwise it will be unconstrained.
Examples
Configuration declarations are allowed to reference Verilog modules in the entity aspects of component configurations. However, the configuration declaration cannot extend into a Verilog instance to configure the instantiations within the Verilog module.
Model Technology Incorporated Voice: (503) 641-1340 Fax: (503)526-5410 www.model.com sales@model.com |