The symbol of 2XOR, shown in the figure below, may be created in the following way:
1. Double click Library in the Project Explorer to launch the Library Editor.
2. Select the SYMBOL tab in the bottom. The Editor screen appears with a single entry placed on the screen. This entry is located at X, Y location 0,0 and its entry number is 1 indicated by the “+” sign. An entry is a point at which the connections to a component pin are made. All other entries added later will have an “x” sign. Along with the first entry, the system also places the COMPNAME and COMPDESC text. The COMPNAME refers to the packaged component’s prefix, like U1. The COMPDESC is information about the component like 7486, 74LS86 etc. Zoom down for proper visibility. Turn ON the Grid by enabling the grid from the dropdown,.
The value for the grid may be selected from the drop down list as .0500”.
3. To create the outline for the 2XOR symbol, click Create Graphic Item tool and select the tool Create line.
4. Click the cursor anywhere on the workspace. A highlighted line appears attached to the cursor. This position will denote the starting point of the line. Click the left mouse button to anchor the line. Move the cursor horizontally along the work space upto a point where the required length for the line is obtained. Press the left mouse button to fix the line at the desired position.
5. Place another line, few grids (8) lower but parallel to the first line.
6. Now draw an arc such that it passes through the ends of the two lines. Select the tool Set Contact Point. Choose Place Point P1 and click on the point just above the end of the upper horizontal line to mark the starting point of the arc and press the left button to place a point there. Similarly place the second point using the tool Place Point P2 to mark the end point of the arc.
7. Select Create Arc from the functional tool Create graphic item. Click anywhere near the contact point to get a phantom arc tagged to the cursor. After adjusting the size of the arc, click to place it.
8. Adjust the arc, if necessary, by selecting the Stretch Item function tool and click the Stretch arc by radius tool or press F1 key, to change the radius of the arc. Move the cursor to the inner side of the arc and click. We see the arc’s radius expands and contracts with the movement of the cursor.
Tip: Pressing the SHIFT key while relocating/ stretching an item allows the item to move/ stretch smoothly.
9. Ensure that the arc is of required shape and size. Repeat the same arc using the tool Repeat Graphic Item and place it as shown below.
10. In the same way draw an arc to define the curved side (near the output pin) of the XOR gate.
11. Place the other arc in the opposite direction.
12. Now select the Create graphic item tool and select the option tool and join the entry pin to the periphery of the symbol outline using this line. Since the part of the outline is curved most parts of it do not lie on the grid and hence it will not be easy to stretch the line with the snap settings.
The first option is to switch off the Snap (or press SHIFT) and then stretch the line till it reaches the symbol outline. A other (better) option is to change the length of the line using its Property window. To do so, first create a line spanning across two grids (0.1000”). Click in the workspace, keep the mouse over the point of the symbol outline where the line has to intersect it and note the X coordinates (using long cursor is recommended so that the X coordinate selected is on the same horizontal level as the line) and then press ESC. Now invoke the property window by selecting the last Function tool Properties enter the coordinates in End X and press enter. Use the Repeat Graphic Item tool to repeat the line and place it on all the three pins.
13. Place the first/ default entry (+) exactly at the starting point of the first pin of the XOR gate using the Relocate tool.
14. We will now place the remaining two entry points Select the Create graphic item tool and click the Create entry pin option tool or press F6 key, for creating the entry points. Move the cursor along the workspace to the second input point of the symbol and press the left button. The entry point is placed at the required position and displayed as a small “x”.
To view the entry number, switch ON the options View | Symbol | Entry number.
15. Another way of adding an entry is to use the Repeat Graphic Item tool. Click on an entry, a copy of the entry is tagged to the cursor, place it at the output pin.
16. Now the graphical construction of the symbol is over and the Simulation Function of this symbol has to be assigned if the primitive DLL is available.
Note : Refer tutorial on Simulation to learn more about Simulation Functions and primitive DLLs.
Select the option tool Symbol properties from the function tool Properties. Triple click (click thrice in quick succession) on the grid cell adjacent to Simulation Function, a dialog box listing the available Simulation Functions is displayed. A list of all the digital components with the same number of pins appears. Select the one that matches the functionality of the symbol, for 2XOR , this is +528 and press ACCEPT.
If the symbol is to be used for SPICE simulation, select the grid cell adjacent to EDSpice Elementcode and click thrice on it in quick succession (triple click) to launch a dialog, select the model corresponding to 2XOR ie. D_XOR and press ACCEPT.
Select Symbol type clicking in the grid cell adjacent to it. Browse through the treeview in the sequence Digital | Gate | XOR. Enter a friendly Symbol description in the grid cell adjacent to it, say 2XOR.
17. Select the Properties tool to view and edit the entry properties. Click on left top input pin of the symbol created. A dialog box appears as shown in figure below.
Note: If the Swap level is set to 1, pins may be exchanged with any other pin. If set to –1, swapping of pins is not possible. For e.g., pins 1 and 2 of the XOR gate can be swapped because both are input pins but the output pin should not be allowed to swap. So we set the swap level for input pin of XOR as 1 and that of the output pin as –1.
Click after completing the settings for the first pin.
Click on the second pin and make settings similar to that of first pin and press ACCEPT. Then click on the output pin, make the necessary settings (set Swap Level to -1) press ACCEPT and finally press CLOSE button to return to the workspace.
18. After assigning the Simname, we will have to position the COMPNAME and COMPDESC texts. Select the Relocate function tool. Click on the text and place it at the required position.
19. The display of PIN ATTRIBUTE (denoted by PA) texts alongside the pins may be enabled using View/ Symbol/ PA Text. Select the Relocate function tool. Click on the PA Text of the first entry and place it near to the pin. Similarly, the PA Texts for all the other pins may be repositioned.
20. Save the symbol to a disk library. If a new library is created, add it to the search sequence. Return to the Part Editor by selecting the Part tab below.
In the same way symbols for NAND, INV etc. may be created.
Tips: To create an arc without defining the contact points, select Create Arc from the function tool Create graphic Item and click on the workspace. A phantom arc is attached to the cursor. Position the other end of the arc (not the cursor end) at the point where the arc should start and click. Stretch the cursor to get the required curve and click to complete the arc.
Note: Library Editor allows to create the symbols automatically using the Symbol Creation Wizard feature. To autocreate the symbols you have to select the option File / New Symbol using Wizard at the start of creating the symbol