DVT VHDL IDE User Guide
Rev. 22.1.15, 18 May 2022
The Code Factory allows you to easily generate instances, signals and testbenches starting with modules or entities.
It is required that you first set an input. Right-click on the element definition and select from the context menu the option Set Factory Input under Code Factory.
The current input persists until a new one is set or until a full build is invoked.
Note: The input can be either a SystemVerilog module, interface, program, checker or a VHDL entity.
Having set an input, you can do one of the following:
The code will be inserted at the cursor's current position.
Any information or errors during Code Factory operations are shown in the status bar.
Create from Template
You can customize the output of the Code Factory using FreeMarker Templates. API is available on the FreeMarker model root.
In the script template you can access structured data describing the design which has been set as factory input. The design is represented by the model root.
The following API is accessible in the FreeMarker template:
<#assign entity = root>
<#--Determine the max length for ports -->
<#--print ports -->
Note: More examples are available in the Code Factory predefined project (DVT Examples > Misc > Code Factory)