21 February 2006

Characterizing Cells and Writing a Technology Library File


The standard cell library we are creating needs to be integrated with the cadence synthesis tool,build gates. In order for build gates to correctly synthesize your circuit it needs to know timing and loading information about the standard cells in the library. You will need to generate simulation data in order to write your technology library.

We will write the technology file in the file format created by Synopsis using this sample technology file.  The reason for this is that the synopsis technology file format is much more readable than the build gates technology file format. After writing the synopsis style technology file we will translate it to the style build gates expects by using the translation tool.


  1. Capacitive Unit Load
  2. Rise and Fall Time Measurements
         a. Test File
         b. Propagation Rise and Fall
         c. Rise and Fall Resistance
  3. Examining a Technology Library File
  4. Compiling the Technology Library File
  5. Creating a Verilog Interface Description

Note: Emacs nicely highlights the syntax in this file if you turn on c-mode. Another note: this sample technology file wasn't made for the geometries we are using in class. While the format and generic parameters in the file will not change, the specific capacitance and timing information will. The final section of this document explains every section of the technology library file. Because a few of the sections are harder to generate data for, we will focus on them more exhaustively. They are the sections you need to customize: the capacitive load unit, the delay threshold points and the cell function.

Capacitive Unit Load

Within the technology file, you will have to include the relative capactive load of each pin.  This is a simple matter of calculating the area of your transistor from your layout and plugging it into the equation.

The capacitive load unit lets us define all the capacitances in the circuit in terms of the standard load which is defined as four inverters. Every cell defines its pin capacitance in terms of this load. If you look at the inverter section of the technology library you will see that the input capacitance on pin A is 0.25, one quarter of the standard four inverter load.

Let's calculate the capacitive load unit for our standard cell library. The input pins of a standard cell connect to the gate of one or more nmos and/or pmos transistors. An oxide layer insulates the gate poly layer from the substrate creating a capacitor. Mosis reports process parameter results from fabrication processes and from these reports we know the value of gate oxide capacitance per unit area for the AMI ABN process is
Cgox= 1.1 ff/u2

The total capacitance at an input pin is the sum of the areas (W*L of the transistor gates multiplied by Cgox).  The inverter input pin, A, is connected to both nmos and pmos transistors with dimensions W/L=3.6/1.2 (nmos) and W/L=10.8/1.2 (pmos).

The total capacitance equals

CpinA=[(W1*L1) + (W2 + L2)]Cgox

= [(3.6*1.2) + (10.8*1.2)]*1.1*10^-15

= 0.019*10^-12

Calculating the standard capacitive unit load simply involves calculating the input capacitance for an input pin connected to four inverters.

Cstandardload= 4*CpinA = 0.076*10^-12

The normalized capacitance of a single inverter is therefore

CpinA(normalized)=0.019pf/0.076pf = 0.25.

When calculating your pin capacitances:
    1.) Determine how many transistors the pin connects to.
    2.) Add up the areas of the transistor gates.
    3.) Multiply by Cgox =1.1
    4.) Divide by the capacitive unit load

Normally output pins do not connect to any transistor gates, so they do not have any capacitance. If for some reason the output pin does connect to the gate of one or more transistors you need to follow the same steps in determining its capacitance.  When does an output pin connect to a transistor gate? (Hint: think about flip-flops)

Rise and Fall Timing Measurements

You will also need to put your rise and fall timing measurements into the technology library file. The delay threshold point defines the rise and fall percentages for propagation timing measurements and the slew threshold point defines our rise and fall percentages for resistance timing measurements. Propagation delay is usually measured as the time between a 50% input change and 50% output change, but in order to avoid negative delay caused by slow changing outputs we will measure the time between a 30% input change and 70% output change. Propagation delay is measured when not driving a load. On the other hand, resistance timing is measured while driving a load. For this measurement, calculate the time between a 10% input change and a 90% output change.

The synthesis tool uses these times along with the capacitance of the standard load to calculate the rise and fall resistances. Rise and fall timing measurements fit into two categories, propagation times and slew rates. The technology library uses intrinsic rise and fall to record propagation times and it uses rise and fall resistance to record slew rates. This section describes the post layout simulation environment used to measure intrinsic rise, intrinsic fall, rise resistance and fall resistance.

A) Test Library The first thing you need to do is create a new library called testLib. It will contain all the schematics you use for testing your standard cells. Link the library to the AMI12 technology library. Create a cell called test for your timing measurements. Also, remember to change the model types of the transistors to ami12N and ami12P.

B) Propagation Rise and Fall

When characterizing a cell's propagation delay, use the setup in Figure 1. Choose vpulse and vdc from the NCSU Analog parts. Set the source parameters as follow:

    Voltage 1 = 0V
    Voltage 2 = 5V
    Delay time = 0ns
    Rise time = 2ns
    Fall time = 2ns
    Pulse width = 25ns
    Period = 50ns

Your schematic should look similar to the one below. Notice the inverter in the test setup. It is used to simulate a real driving device and should use the schematic cell view. It should be connected to the input you are testing, while the other inputs can be held as non-controlling inputs. For NAND logic this is high, and for NOR logic this is low - just think about what way you would have to hold the other inputs so that the input you toggle will toggle the output. The second device is the part being tested and should use the analog extracted view.

In the Library Manager window, create a new cell view for the invertersim cell. Go to File -> New -> Cell View ... In the Create New File window that appears, type config in the "View Name" field and the "Tool" field should automatically change to Hierarchy-Editor. If not, change the "Tool" field manually. Select OK.

Two windows will appear. In the New Configuration window, select Use Template, and select "spectreS" in the "Name" field drop-down list. Select OK.

Make sure that the library is testLib, the cell is the name of the test schematic you created, and the view is schematic. The global bindings should also have appeared.

The following window will have appeared. Right click on the device you are testing and select Set Instance View -> analog extracted.

You can also change the view to tree mode by selecting view->tree.

Save and close the config window and from your schematic select Tools -> Analog Environment.

From the window that appears, you will be editing three setup conditions: Design, Simulator/Directory/Host, and Model Path. First, go to Setup -> Design. Choose the the test that you are running and select View Name to config.

Next change the simulator to spectreS by going to the Setup -> Simulator/Directory/Host window. Make sure it looks like the following:

Next change add the model path that contains the AMI12P.m and AMI12N.m files.  Go to Setup -> Model Path.  Type in /ee2/Cadence/local/designkits/BYU/lib/AMI12/models/spectreS.  Click the add button.

Now from the Analog Environment window, go to Analyses -> Choose, and select transient with an amount of time to run. It should be at least two times the period of your longest vpulse.

To select what signals you want to view, go to Outputs -> To Be Plotted -> Select on Schematic. Select the output and the input you are toggling (after the inverter buffer).

Now run the simulation by clicking on the green light button.

After running your simulation, use the resulting waveforms to calculate the 30-70 rise and fall times for the input pin A. Write these down, you will need them when you write the technology library file. If the device under test has more than one input, i.e. a nand gate, then calculate the propagation rise and fall times separately for each input.

For instance, to test B, hold A high and toggle B. Likewise, to test A hold B high and toggle A. Refer to the sample technology library file, notice how pin Out has a timing section related to pin A? Each input pin has its own timing section in the output pin section of the cell definition. If this were a nand gate, the output pin section would have two timing sections, one related to pin A and one to pin B.

C) Rise and Fall Resistance

Measure the rise and fall resistances by removing the noLoad output from the device under test (DUT), wiring the inv to the output of the DUT and creating a new output pin on the output of the DUT called Load. Name the wire in between the DUT and the output. Run the simulation again and this time measure the 10-90 rise and fall times of the DUT. Record these for use in the technology library file. Similarly to the propagation time measurements, each input pin is timed separately for the resistance measurements.

Examining a Technology Library File

Create the File

You should put your technology file in your standard cell library folder. Navigate to the folder named stdCellLib and use your favorite text editor to create a file called stdCellLib.lib. By now you have an example of a technology library file and a good idea of what goes in one. We are going to write the library portion for your file as well as the inverter section. As a side note, you only need one file for your entire library. As you create and add more cells to the library, simply add a new cell definition section for each new cell.

Write the File