Languages

CommunityCategory: GLISTERInserting Verilog codes to model schematics

GLISTER

Inserting Verilog codes to model schematics

SA Support Team Staff 2019-04-23

I am composing models in schematic form using the XMODEL primitive symbols in GLISTER. Sometimes, I’d like to insert a few lines of Verilog codes to the netlist generated from my model schematics. Is there a way to add those Verilog codes to the model schematic in advance so that the Verilog codes can be automatically inserted during netlisting?

1 Answers
Best Answer
SA Support Team Staff 2019-04-23

Yes, you can use the 'inline' primitive of GLISTER to do this. The 'inline' primitive lets you insert short Verilog codes to the model netlisted from the schematic view.

To use this 'inline' primitive, first place an instance of the 'inline' primitive symbol to your schematic. Note that the 'Open Inline Module Editor' button in the "Add Instance" dialog window won't work unless you place an instance first.

Once the instance is placed, select the instance and press the 'Q' short-cut key or select the "Edit Properties" pop-up menu. When the "Edit Object Properties" window shows up, click the "Open Inline Module Editor" button to open the "Edit Inline Module" window.

From the "Edit Inline Module" window, you can list the Verilog codes you'd like to insert in the "Inline Source" field. If the Verilog codes need to access the signals on the schematic, you can define I/O ports in the "I/O Ports" field and connect the desired signals to the ports of the 'inline' primitive symbol. If you'd like to edit the content using a full-featured text editor, you can click the "Open in Text Editor…" button. However, we recommend using this 'inline' primitive only for inserting short Verilog codes. For longer Verilog codes, consider creating a separate 'xmodel' or 'verilog' view that imports the source file (see the GLISTER User Guide for more details).