Documentation

Writing models

Back to Model import or creation


If a modelcard/subcircuit (see Models in (P)SPICE and TARGET 3001!) is not needed or not available:

Components in the schematic or in the library can be supplied with models. The operation is identical in both cases, starting from the models dialog.

Either by calling the models dialog for a component in the schematic:
USER: Doubleclick the symbol (see also Edit the circuit).
TARGET: Dialog "Change symbols" will appear.
USER: Click the button "Models".
TARGET: Dialog "Models for ..." (models dialog) will appear.

Or by calling the models dialog for a component in the library:
USER: Open the library browser; Press the function key F2 in the schematic view (also with the menu file).
USER: Switch to the component selection and unfold the desired branch.
USER: Select the desired component with the right mouse button.
TARGET: Popup menu will appear.
USER: Select menu item "Edit component model".
TARGET: Dialog "Models for ..." (models dialog) will appear.

Starting from the models dialog:
USER: Click the button "Add".
TARGET: Dialog "New model for ..." will appear.
USER: Click button for a certain primitive or a subcircuit.
TARGET: An appropriate model dialog for the selected item will appear.

If it should be a primitive:

USER: Enter parameters, which are not specified in the modelcard.

Some model dialogs for primitives contain an input box for the name of the modelcard, which has to be used. In this box all modelcards of the appropriate modelcard type are listed. This box allows to select an existing modelcard, to import an available modelcard or to create a new one.

If a modelcard is needed:
USER: Open box and select NEW.
USER: Enter name for new modelcard.
INFO: The name of a modelcard should be meaningful!
TARGET: The modelcard will be generated and filled with default values.
TARGET: The new modelcard will be selected.
INFO: The parameters of the modelcard will be shown in the same dialog, although the modelcard does not belong to the component! Several components can use the same modelcard!
USER: Enter parameters.
INFO: The meaning of the parameters is visualized for many models. Also hints to the input fields will appear by moving the mouse pointer to the input field. The parameters for the semiconductor models are described in detail in the literature (see appendix).
INFO: Naturally the new modelcard will be listed at the model browser.

If it should be a subcircuit:

The dialog contains an input box for the name of the subcircuit, which has to be used. In this box all subcircuits are listed. This box allows to select an existing subcircuit, to import an available subcircuit or to create a new one.

USER: Open box and select NEW.
USER: Enter name for new subcircuit.
INFO: The name of a subcircuit should be meaningful!
TARGET: Subcircuit dialog will appear.
USER: Write subcircuit: See How to write modelcards or subcircuits
USER: Quit dialog with button OK.
TARGET: The subcircuit will be generated and selected.
TARGET: All parameters will be listed, which have been declared in the subcircuit.
USER: Doubleclick a certain parameter to edit its value.

Regardless of a certain component, a modelcard or a subcircuit can be created with the model browser (see next chapter), but in case of a modelcard, the correct type of modelcard must be selected prior to the primitive!

Now it is necessary to do the pin assignment!
USER: Click the button pin assignment.
TARGET: Dialog for the pin assignment will appear, each pin of the component is listed in the left top window with its symbol affiliation, pin name and pin number.
TARGET: All "pins" of the model are listed in the right bottom window.
USER: Drag&Drop the pins (pin numbers) of the component from the left side to the nodes.
USER: Quit pin assignment dialog and model dialog with the OK button.
USER: Info and level for the instance can be registered in the models dialog.