The object of this tutorial is to take a closer look at LogicWorks’s schematic editing features. We will do this by making a number of modifications to the circuit file created in the Five-Minute Schematic and Simulation demonstration.
The topics covered in this section are as follows:
- deleting and moving objects;
- selecting device type by name;
- device symbol rotation;
- using power and ground connectors;
- connecting signals by name;
- using Copy and Paste on circuit objects;
- naming devices;
- adding pin numbers to devices;
- placing text notations on the diagram
Opening a Circuit File
- Open the file you created in the initial demonstration by clicking on the Open button () or selecting the Open command in the File menu, or open the file that was supplied with LogicWorks in the Examples folder.
- If the simulator is running, click the Stop () button to turn it off, as we will only be looking at schematic editing tools for now.
Deleting and Trimming Objects
- Select the Zap () tool in the toolbar. The cursor will change to match this icon.
This tool is used to remove a single object from the diagram. When clicked on a device, the device is removed. When clicked on a signal line, the line segment is removed to the nearest device pin or intersection.
- Zap the segment shown.
The signal has now been broken into two pieces. The signal name FEEDBCK may become associated with the closest piece or might be deleted automatically if it is too far from any of the remaining segments. You can click on the name to see which piece gets highlighted.
Rotating a Device
- In the Parts Palette, double -click on the device Buffer-1 O.C. (in the simulation Logic library). Move the mouse pointer over to the Schematic window.
- Before placing the device, try pressing the arrow keys on the keyboard. Notice that the arrow keys change the orientation of the device symbol that is moving on the screen.:
|Press left arrow for |
Press again for
|Press right arrow key for|
Press again for
|Press down arrow for|
Press again for
|Press up arrow for|
Press again for
There are actually eight different orientations available: the four major compass points, plus these directions with an additional flip around the major axis. The orientation also applies when groups of objects are pasted or duplicated.
Placing a Device
- Place one of the open-collector buffers on the diagram as shown:
The open-collector buffer is a device that converts a low input into a low-impedance output, and a high input to a high-impedance output. How this device works in conjunction with a pullup resistor will be demonstrated in the following sections.
Power and Ground Connectors
- Select a +5V device from the Parts Palette and place it as shown:
The +5V symbol is called a Signal Connector and performs several functions. It puts out a constant high level for use in the simulation, it assigns the name Plus5V to the attached signal line, and it creates a logical connection to all other signal lines that have the same symbol attached. You can create your own Signal Connectors for commonly used signals by using the symbol editor tool.
- Press the spacebar to reactivate the arrow pointer, and then wire these devices together as shown.
Dragging Groups of Devices
- Select the three symbols highlighted in the following diagram by SHIFT-clicking on them:
- Drag the selected items up away from the 164 device to any convienent location.
Connecting Signals by Name
- Select a NOT (Inverter) from the Parts Palette, and place it below the 164 device as shown.
- Select the Text () tool, and name the input on the NOT device as D7 as described in the introductory demo. Be careful to click the pencil cursor at the end of the pin. Clicking in the middle of the pin will create a pin number.
When you place the label D7, you will notice that this line will flash, indicating that a logical connection has been made. For simulation and netlisting purposes, these two signals are now connected together. Any like-named signals are considered to be connected.
- Double-click on either of the D7 signal lines (that is, along the line segments, not on the name itself) to check connectivity. (Both lines will change colour.)
- Label the output of the inverter as NOTD7, and observe the inverted signal in the Timing window.
Using Copy and Paste
Now we will use the clipboard commands to copy a selection of the circuit to a new circuit file.
- Select the group of circuitry to be copied by clicking and dragging across the group of objects. Any object that intersects or is contained within the rectangle will be selected, such as in this diagram:
- Select the Copy command from the Edit menu.
- Select the New command in the File menu, and choose the Circuit option.
- Select the Paste command in the File menu.
An outline of the entire circuit will now follow your mouse movements. You can place this group of objects anywhere on the new diagram. You can also use the arrow keys to reorient the circuit group before placing it.
The Cut, Copy, Paste, and Duplicate commands can be used on any single object or any group of selected objects.
- Select Close Circuit on the File menu to close the extra copy of the circuit without saving. The original circuit window should still be open
Devices are named in a manner similar to signals:
- Select the Text () tool in the toolbar
- With the pencil inside the device, click the left mouse button.
- Type the desired name.
- Press the ENTER key or click the left mouse button once.
- Repeat the above steps to name the devices as shown
Device or signal names can be moved after they have been placed by dragging them with the pointer. They can also be edited by clicking an existing name with the pencil cursor.
Device names are used not only as labels on the schematic, but also in component lists and bills of materials.
Setting Device Attributes
- Right-click the Clock device.
- In the pop-up menu, select the Attributes command.
LogicWorks has a fixed number of different attribute “fields”” that you can use to store auxiliary device information like component lists and bills of materials.
- Click on the Value item in the field list.
- Type the value 14.288 MHz in the text box, as shown.
- Verify that the Visible option is turned on.
- Click the Done button.
Notice that the value that you typed in has now appeared adjacent to the selected device. This text can be moved to any desired location relative to the device.
IMPORTANT: The value is a text annotation only and has no effect on the simulation of the device. Use the Simulation Params command to set simulation values.
- Select the Text cursor again, and click it on a signal line very close to a device symbol, as shown.
A blinking insertion marker will appear immediately next to the device.
- Type up to four digits or letters for the pin number, and then press the ENTER key or click the left mouse button once.
Pin numbers can be positioned only directly on device pins and cannot be moved. Pin numbers are used to distinguish device pins when a netlist is created. Most non-primitive library devices have pin numbers already defined for the most common package type. The default pin numbers can be specified in the symbol library, or they can be edited right on the diagram.
Placing Text on the Diagram
- The Text cursor (), but not near any device or signal line, and a blinking insertion marker will appear at that point.
- Type any desired text, using hard returns to create multiple lines.
- Click the left mouse button once to terminate typing of the text item. The results should look like as follows:
- Right-click on the text block that was just created and select the Properties command. This command allows you to set the text font, colour, framing, and other visual aspects of the text notation.
Creating a Bus
A “bus” is a single line on the schematic that represents a group of related signals.
- Using the editing techniques we have covered so far, move the XNOR, NOT, and Probe devices to the right as shown in the following diagram (exact position is not important):
- Remove all lines and signal names connecting to the outputs of the 164. Also remove the label from the NOTD7 device (using the Zap tool). This will leave room to create the bus connections
- Select the New Breakout command in the Schematic menu.
A “breakout” is a special symbol that indicates connections between regular signal lines and bus lines. The only way to connect a signal line into a bus is to use a breakout.
- Type the text D0..7 (the second character is a zero, the the letter O) into the pin list box as shown in the following screen shot:
- If necessary, change the pin spacing to match the illustration.
- Click the OK button.
The text D0..7 tells LogicWorks to create a breakout with eight signals D0, D1, D2 etc., up to D7. The signals don’t have to be sequentially numbered. You can also type any collection of names separated by spaces or commas, such as CLK ENABLE CTRL.
- Place the new breakout symbol as shown so that its pins just make contact with the eight outputs of the 164. You will have to use the left arrow key on the keyboard to orient it in the direction shown.
- Press the spacebar to reactivate the arrow cursor.
- Drag the breakout symbol a little to the right to make more room for the signal names and pin numbers. This is done by clicking in the diagonal-line area of the breakout symbol.
A breakout can be treated just like a device symbol for editing purposes. The diagonal-line area is the breakout symbol. The wide “back bone” of the breakout symbol is actually a bus line. You can now extend the bus in either direction from the breakout just by clicking and dragging at either end of the bus line.
- Use the New Breakout command three more times to create small breakouts as shown. For the top one, type “D6 D7” or “D6..D7”. For the middle one, type just “D0” and for the bottom one, type “D7”
IMPORTANT: Signals are not connected by name between different busses. At this point, we have three different signals called D7 that are not connected together. They will become connected together in the next step when we join the busses.
- Using the arrow cursor, join the bus connections of all the breakouts together as shown in the following diagram. Connect one breakout to the next; do not try to connect all three at once.
- Verify that the circuit still simulates correctly now that the connections are made through busses instead of directly. You may need to use the Clear Unknowns () button in the toolbar to remove any X values that appeared when we broke some of the connections.
- Save the file you have created to this point for use later on.
This ends the tutorial on general schematic editing.
Next tutorial is Structural Simulation..