Creating a Simulation Subcircuit for a Symbol
Purpose of This Note
This DesignNote describes methods for defining the simulation characteristics of a symbol by creating a subcircuit block.
This note is primarily aimed at users of LogicWorks (the student version of DesignWorks Professional), but the same techniques apply to DesignWorks, with some slight variations in menu commands.
| This note applies to: |
Windows |
Macintosh |
| DesignWorks Professional |
3.0 + (with simulator option) |
3.0 + (with simulator option) |
| DesignWorks Lite |
N/A |
N/A |
| LogicWorks |
3.0 + |
3.0 + |
| Notes: N/A - not applicable to this version. "3.0 +" indicates version 3.0 and later. Since this note may apply to multiple versions and platforms, there may be some variation in exact configuration of menu commands and screen layouts from that shown in this note, but the same principles apply. |
Introduction
There are a variety of ways of creating a subcircuit and attaching it to a symbol for simulation purposes. Here is a simple procedure that works, although you can use your knowledge of the package to try different procedures.
NOTE: There are some differences in menu commands between the Macintosh and Windows versions and between version 3 and version 4.
We will assume we are making a subcircuit containing only a 2-input AND gate.
Make a new, empty circuit window by:
 |
(Windows v 4) selecting the File/New command and choosing the Design option |
 |
(other versions) selecting the File/New Design command. | |
|
| Create the subcircuit, adding Port Connector symbols for each location where you want to make a connection to a pin on the parent symbol. In this case: Place an AND-2 gate from the Primitive Gates (primgate.clf) library. To the left of the gate, place two Port In devices from the Connectors (connect.clf) library. Connect the pins on the Port In devices to the inputs on the AND gate. Place a Port Out device to the right of the AND gate and connect it to the output pin on the gate. |
 |
| Place unique port names on the three port connectors using the pencil tool. Specifically: Select the pencil tool in the tool palette. Click on the first Port In symbol. Type the name "INA" and hit Enter. Click on the next Port In symbol and type "INB" and Enter. Click on the Port Out symbol and type "OUT" and Enter. The subcircuit is now complete. You don't need to save it. |
 |
Create a new, empty device symbol by:
 |
(Windows v 4) selecting the File/New command and choosing the Device Symbol option |
 |
(other versions) selecting the Tools/DevEditor command. | |
|
| In the Options menu in the DevEditor window select the Subcircuit/Part Type command. |
|
| Select the second option "Create a sub-circuit symbol and select an open circuit to attach to it" or "Create a subcircuit symbol and store the subcircuit with it" (depending on program version). When you click on this option, a box will appear containing a list of all open circuits. Select the one you just created. |
 |
| Click the Done button on the Subcircuit/Part Type box. You should now see the three pin names in the pin list on the left. |
 |
| Select the Autocreate Symbol command in the DevEditor's Options menu. |
|
| Click the Extract Pin List button. This will place the three pin names in the appropriate boxes. |
|
| Click the Generate button. This will create a symbol. You can modify the symbol graphics if you want. |
 |
| Select the Save As command in the DevEditor's File menu and save the new part to your own library. Do not modify any of the standard LogicWorks libraries. |
|
Your part is now ready to use. Create a new, empty design and verify that it operates like an AND gate.