Create PostScript And Netlist Using XCircuit

Sneha Ambastha

0
23028
Fig. 1: Symbol example
Fig. 1: Symbol example

With so many design tools and features, it is really difficult to identify which design tool to select without knowing about its features, working ability and advantages. Above all, the most important thing is to find out how easy the tool will be to use.

Many times, you come across a situation where the tool is so complicated that learning it takes more than three months, while you have only four months to complete your design. Here is an attempt from EFY to help you understand XCircuit to an extent that you will be able to make the right choice.

Initially designed as a drawing program for undergraduate electrical engineers by Tim Edwards, XCircuit is now used worldwide not only for presentations but as an electronics design and automation (EDA) tool, too. Although the main purpose of XCircuit is to help create electric circuit models, it also allows you to create other two-dimensional schematics, like music typography, NAND gate, etc.

It makes the task of creating complex circuits easy with the use of some basic design elements, like circles, lines and rectangles. These design elements can be rotated, flipped and joined to create desired circuit schematics that are used by the schematic capture to produce circuit netlists.

Fig. 2: Initial circuit window when starting XCircuit
Fig. 2: Initial circuit window when starting XCircuit

Unlike other design tools, XCircuit considers all circuits to be hierarchical, and thus provides hierarchical outputs. Edward says, “I use XCircuit probably more than any other tool, including for writing-out piano and violin scores and for writing Christmas cards.”

Graphical programming advantage
Usually, what do you do? Create a circuit design using a design tool, write programming codes and then use the suitable format of codes in the circuit to check its working. In this process, you are required to learn a programming language (assembly-level or hardware-level) to start with, which is quiet time-consuming.

8D6_box161_box_2

But, at the same time, if we have graphical design tools with which we do not have to spend time on coding, design graphics and the code for that will be auto-generated, like in case of MATLAB, it will be advantageous.

Designers get this opportunity with XCircuit that uses a PostScript file format for both input and output. PostScript is a programming language that gives publishable quality circuit diagrams as outputs. Unlike most graphical programs that provide output in a custom format (for example, .fig files for xfig) that can be translated to other graphical formats, PostScript is in ASCII format and need not be translated as it is widely-accepted.

This platform-independent programming format allows one to hand-edit the output and view its source in detail. Being an interpreted language, PostScript helps XCircuit to create a set of definitions that can help it overcome a set of issues related to circuit drawing. The expansion of the set makes these compatible with earlier versions.

Although PostScript is a printer language, it saves files in the same format that is used to print these. Thus, printing output designs with XCircuit is not that tough.

From 2D architectural designs to PCBs
As discussed earlier, XCircuit can be used as a generic program to draw 2D designs and circuit architecture. You can design the architectural drawing, music typography, printed circuit boards (PCBs) and almost anything that requires the use of repeated standard set of graphical objects.

F55_Fig_3
Fig. 3: Front-end schematic

Create your own library. Although the main aim of XCircuit is to create circuit diagrams, it can also be used to create symbols that can be saved in a library and used later during circuit design. Tim Edwards, who wrote XCircuit, says, “I created an example symbol in a library in XCircuit. I can now use that symbol as part of any drawing in XCircuit if I wanted to. I think XCircuit would be a good choice for arbitrary diagram drawing needs.”

Easy LaTeX embedding. PostScript (.ps) format of files saved in XCircuit allows you to embed the circuit in LaTeX document easily. As LaTeX works on TeXnicCenter, you only need to open the document and select Insert Picture to use the saved file.

Recover files on crash. XCircuit has been created in a way that a copy of its current work is saved in the temporary (/tmp) directory, which is removed when you exit the program. However, if the program shuts down unexpectedly, or if the system crashes, the current work remains in the/tmp directory.

Now, you open XCircuit again. It will prompt you to recover the file in the same way as Microsoft Office or Open Office. However, this feature has a small shortcoming. XCircuit creates a backup of files periodically, once in every ten minutes. Thus, changes made in the last few minutes of the crash do not get updated.

LEAVE A REPLY

Please enter your comment!
Please enter your name here