2017年3月2日 星期四

How to Create Symbol from Schematic & Perform Simulation in Cadence

I am not an experienced researcher, as well as not good at setting up the environment in either Cadence or Linux. I am slowly learning all these things, so to start with today I will talk about simpler stuff. I mainly rely on HSPICE to perform simulations and Cadence for layout. After one year of not doing any simulations I have already forgotten how to create symbol from schematic and perform AC/TR simulation in Cadence 5, too bad. Let's get started.

Assume that you have already completed the schematic so you wish to create a symbol of it to perform simulations. This is a very convenient way as you only have to deal with 1 block instead of 30 or more transistors. Follow the steps below to create a symbol from a schematic:

1. Go to “Design” -> “Create Cellview” -> “From Cellview”
2. Make sure the chosen schematic is correct (Cell Name), and choose “Composer-Symbol” in “Tool / Data Type”. Click “OK” if everything is correct
3. Input the desired “Left Pins”, “Right Pins” etc. This does not affect the operation of the block but only the pin assignment of the output block (symbol)
4. You should be able to see that a symbol is created from the schematic of your designed circuit after Step 3

Now you have created a symbol of your designed circuit. You are strongly recommended to perform simulations of your circuit in Cadence before proceeding to the layout part to make sure you did not mess up the schematic. Check to see if the simulation results match your HSPICE simulations. Now:

1. Click “File” -> “New” -> “Cell View” to create a new cell view under your library
2. You can create separate cell view for AC simulation and TR simulation as you do not need to remove certain instances and reconnect everything every time. Make sure you select “Composer-Schematic” in “Tool”
3. Add the symbol of your designed circuit into this schematic, and add other instances needed e.g. ideal capacitor (cap), inductor (idn), DC current source (idc), DC voltage source (vdc) etc. If you need to perform AC simulation, use the instance vdc as the input and set the “AC Magnitude” to 1. If you need a pulse input then use vpwl or vpulse and set the respective values of pairs of points.
4. Now you can start to perform simulation. In this case we are using AC simulation as an example. Go to “Tool” -> “Analog Environment”
5. A new window should pop up. Check to see if your design is selected. Then click “Choose Analyses”
6. Select “ac” in “Analysis”, “Frequency” in “Sweep Variable”, input your desired “Sweep Range”, choose “Logarithmic” in “Sweep Type” and input the “Points Per Decade” you wish to have. Finally remember to click “Enabled” if you wish to perform this simulation (no point to do so many things if you do not want to perform simulation, right?). Then click “OK”
7. The selected analysis should now appear under “Analyses”. If everything is OK then click “Netlist and Run” on the right
8. A new output log will pop up after Step 7. This log file is very important as it contains information of the simulation. If there is any warnings or errors the output log will display related information. Remember to check this log in case you run into any problems
9. Assume that you don’t encounter any fatal errors in your simulation, you can now view the Bode plot. Go to “Results” -> “Direct Plot” -> “AC Gain & Phase” (or any other type you prefer)
10. Then Cadence will ask you to “Select first point” and “Select second point”. C on the output net and the input net to view the Bode plot
11. You can now see the Bode plot. Click “Switch Axis Mode” if you wish to separate the gain plot and phase plot like Fig. 16. You can also click “Crosshair Marker A” or “Crosshair Marker B” to view the output values at different frequencies.

Hope this guide helps (help myself actually). Have a nice day!