0% found this document useful (0 votes)
49 views68 pages

Laboratory 2 - Logic Gates Design Manual

Uploaded by

ece thesis
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
49 views68 pages

Laboratory 2 - Logic Gates Design Manual

Uploaded by

ece thesis
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 68

Laboratory 2

Logic Gates
Design Manual
Logic Gates Design
To design logic gates, you need to create just the ff:
• INVERTER
• NAND
• NOR

**AND Gate is just NAND Gate and an Inverter


- Instance the NAND Gate and the Inverter from the Account’s Library.
**OR Gate is just NOR Gate and an Inverter
- Instance the NOR Gate and the Inverter from the Account’s Library.

INVERTER
- Same with the Inverter made from previous Laboratory. (Refer
to Laboratory 1 Manual)

Note: Create a cell for each logic gate. Always verify the DRC in every cell layout.
Logic Gates || MSU-IIT EECE 2
Logic Gates Design Outline
Part 1: Inverter
Part 2: NAND Gate
Part 3: AND Gate
Part 4: NOR Gate
Part 5: OR Gate
Part 6: Example Combined
Part 7: Test Bench
Part 8: Verification
Part 9: Post Simulation
Logic Gates || MSU-IIT EECE 3
Part 1: INVERTER

Logic Gates || MSU-IIT EECE 4


Inverter

Schematic Symbol Layout

Logic Gates || MSU-IIT EECE 5


Part 2: NAND GATE

Logic Gates || MSU-IIT EECE 6


NAND Gate

Symbol

Schematic

Logic Gates || MSU-IIT EECE 7


NAND Gate

Layout
Logic Gates || MSU-IIT EECE 8
Part 3: AND Gate

Logic Gates || MSU-IIT EECE 9


AND Gate

Click I to add instance then


select the NAND cell.

Logic Gates || MSU-IIT EECE 10


AND Gate

Click I to add instance then


select the Inverter cell.

Logic Gates || MSU-IIT EECE 11


AND Gate
Add pins and wire to finish the schematic design. Click Y to create the symbol.

Schematic

Symbol
Logic Gates || MSU-IIT EECE 12
AND Gate
Create the Layout view.

Click I to add instance then


select the NAND cell.

Logic Gates || MSU-IIT EECE 13


AND Gate

Click I to add instance then


select the Inverter cell.

Logic Gates || MSU-IIT EECE 14


AND Gate

Edit the hierarchy number to


see the various layers. Then
Zoom in or out, you can then
see the inner hierarchy.

Logic Gates || MSU-IIT EECE 15


AND Gate

Move the INVERTER cell to overlap


with the NAND cell. Route the
necessary connections. Add the
input and output pins.

Logic Gates || MSU-IIT EECE 16


AND Gate

Layout
Logic Gates || MSU-IIT EECE 17
Part 4: NOR Gate

Logic Gates || MSU-IIT EECE 18


NOR Gate

Symbol

Schematic

Logic Gates || MSU-IIT EECE 19


NOR Gate

Layout
Logic Gates || MSU-IIT EECE 20
Part 5: OR Gate

Logic Gates || MSU-IIT EECE 21


OR Gate

Click I to add instance


then select the NOR cell.

Logic Gates || MSU-IIT EECE 22


OR Gate

Click I to add instance then


select the Inverter cell.

Logic Gates || MSU-IIT EECE 23


OR Gate
Add pins and wire to finish the schematic design. Click Y to create the symbol.

Schematic

Symbol
Logic Gates || MSU-IIT EECE 24
OR Gate

Click I to add instance


then select the NOR cell.

Logic Gates || MSU-IIT EECE 25


OR Gate

Click I to add instance then


select the Inverter cell.

Logic Gates || MSU-IIT EECE 26


OR Gate

Edit the hierarchy number to see


the various layers. Then Zoom in
or out, you can then see the
inner hierarchy.

Logic Gates || MSU-IIT EECE 27


OR Gate

Move the INVERTER cell to overlap


with the NOR cell. Route the
necessary connections. Add the
input and output pins.

Logic Gates || MSU-IIT EECE 28


OR Gate

Layout
Logic Gates || MSU-IIT EECE 29
Part 6: COMBINATION

Logic Gates || MSU-IIT EECE 30


Ex. AND-NOR
Instance the AND Gate and then the NOR Gate.

Schematic

Symbol
Logic Gates || MSU-IIT EECE 31
Ex. AND-NOR

Click I to add instance


then select the AND cell.

Logic Gates || MSU-IIT EECE 32


Ex. AND-NOR

Click I to add instance


then select the NOR cell.

Logic Gates || MSU-IIT EECE 33


Ex. AND-NOR

Move the NOR cell to overlap


with the AND cell. Route the
necessary connections. Add the
input and output pins.

Logic Gates || MSU-IIT EECE 34


Ex. AND-NOR

Layout
Logic Gates || MSU-IIT EECE 35
Part 7: TEST BENCH

Logic Gates || MSU-IIT EECE 36


Test Bench

Instance the AND-NOR Cell and the rest of the necessary cells for the test
bench. Connect through wires. Check and edit parameter on property window.
Click Q to view property window.
Logic Gates || MSU-IIT EECE 37
Simulation

To open model file.

Select Tools Menu the SAE. Click M to add Model


files. Select TT.
Path: account/TSMC0180UM/models/hspice
Select rf018.l

Logic Gates || MSU-IIT EECE 38


Simulation

Click A to add analyses then edit the


parameters. Then select the wires for
the corresponding expressions.

Logic Gates || MSU-IIT EECE 39


Pre-Simulation Waveform

Click Ctrl+O to open the file to


view in the waveview. Select
the .tr0 file. Click Ctrl+H to
view the Output view window.

Logic Gates || MSU-IIT EECE 40


Pre-Simulation Waveform

Input on pin A

Input on pin B

Input on pin C

Double click the parameters


needed for analysis and view
the waveform. AND-NOR OUTPUT

Logic Gates || MSU-IIT EECE 41


Pre-Simulation Waveform

Use the measurement


tool for the Rise/Fall
Time.

Logic Gates || MSU-IIT EECE 42


Pre-Simulation Waveform

Fall Time

Rise Time

Logic Gates || MSU-IIT EECE 43


Part 8: VERIFICATION

Logic Gates || MSU-IIT EECE 44


DRC Verification

Logic Gates || MSU-IIT EECE 45


DRC Setup

Add Runset file.


Path: /home/documents/TSMC_018um/hercules/drc
Then Click OK.

Logic Gates || MSU-IIT EECE 46


DRC Result

Logic Gates || MSU-IIT EECE 47


LVS Verification

Logic Gates || MSU-IIT EECE 48


LVS Setup P.1

Add Runset file.


Path: /home/documents/TSMC_018um/hercules/lvs

Logic Gates || MSU-IIT EECE 49


LVS Setup P.2

Logic Gates || MSU-IIT EECE 50


LVS Result
This is verifies that the layout design matches the schematic design.
If not, debug the errors.

Logic Gates || MSU-IIT EECE 51


LPE Verification

Logic Gates || MSU-IIT EECE 52


LPE Setup P.1

Select Runset file.


Path: /home/documents/TSMC_018um/hercules/starrc

Logic Gates || MSU-IIT EECE 53


LPE Setup P.2

Go to the lvs folder from the LVS verification.


Path: /home/account/TSMC018UM/Inverter/hercules_lvs

Select Mapping file.


Path: /home/documents/TSMC_018um/hercules/starrc

Select GRD file.


Path: /home/documents/TSMC_018um/hercules/starrc

Logic Gates || MSU-IIT EECE 54


LPE Setup P.3

Select Output Runset Path.


Path: /home/account/TSMC018UM/EE270/AND_NOR/
Create output.sp file.

Logic Gates || MSU-IIT EECE 55


LPE Result
Refer to the Custom Designer Console of This is verifies that the layout design has no errors
in terms of the parasitic extraction.

Logic Gates || MSU-IIT EECE 56


Part 9: POST SIMULATION

Logic Gates || MSU-IIT EECE 57


Post Simulation P.1
Open on gedit the pre-simulation hspice code on
the simulation folder.
Path:
/home/account/simulation/EE270/AND_NOR_TB/
Schematic/HSPICE/nominal/netlist
Open on gedit the post-simulation hspice code on
the simulation folder.
Path:
/home/account/TSMC018UM/EE270/AND_NOR

Logic Gates || MSU-IIT EECE 58


Post Simulation P.2

From the input.sp, copy the highlighted code to the output.sp file just below
the comments line or the line before the Subckt.
Logic Gates || MSU-IIT EECE 59
Post Simulation P.3

From the input.sp, copy the highlighted code to the output.sp file at the bottom part
or after the Subckt code.
Logic Gates || MSU-IIT EECE 60
Post Simulation P.4

In the output.sp file, rename the Inverter pins in sequenced with the pinning of the
Subckt.

Logic Gates || MSU-IIT EECE 61


Post Simulation P.4

Click Replace on the menu bar. Rename the <space>P<space> with


<space>PCH<space> and <space>N<space> with
<space>NCH<space>
Select Replace All.
Logic Gates || MSU-IIT EECE 62
Post Simulation P.5
Go back to terminal, go to the folder
where the post.sp file is located.
Run Hspice.
Type hspice filename.sp then Enter.

If there are no more errors, job


is concluded.
Type wv & then a waveview
window pops up.

Logic Gates || MSU-IIT EECE 63


Post Simulation: Waveform

Open the File


filename.tr0. Click Ctrl+O
to open waveform files
window.

Logic Gates || MSU-IIT EECE 64


Post Simulation: Waveform

Click the
waveforms for
viewing.

Logic Gates || MSU-IIT EECE 65


Post Simulation: Waveform

Use the measurement tool to select


the needed option for measurement.
For this, the Rise/Fall Time is
measured.

Logic Gates || MSU-IIT EECE 66


Pre-Simulation: Waveform

Open the pre-sim file. Path:


/home/account/simulation/EE270/
AND_NOR_TB/schematic/HSPICE/nominal/results
Select the hspice.tr0 file.
Logic Gates || MSU-IIT EECE 67
POST vs PRE-Simulation

PRE-SIM

POST SIM

It is good if your post-simulation is equal to or better than the pre-simulation result. If not,
you can check your layout to improve your output.
Logic Gates || MSU-IIT EECE 68

You might also like