Transistor operating point printer: Difference between revisions

From ift
mNo edit summary
Line 35: Line 35:
[[File:Csv_import_libreoffice.png | 500px]]
[[File:Csv_import_libreoffice.png | 500px]]


[[Category:Mikroelektronikk]]
[[Category:Mikroelektronikk]] [[Category:Integrated_Circuts]]

Revision as of 13:32, 15 September 2017

This script can be used to print the operating point parameters of all transistors in your design.


Navigate to the folder you want to save the script in (this tutorial uses the home (./) directory) and create a new file in the terminal by entering touch transistors.ocn . Open the file by writing gedit transistors.ocn & and copy the following script into the document. Change ./transistors.csv in the script if you want another output file name and/or location. Save the file.

selectResult('dcOpInfo)
report(?output "./transistors.csv" ?param list("gm" "gmb" "gmoverid" "gds" "id" "idsat" "vth" "region" "cgs" "cgd" "self_gain" "type" "vds" "vdsat" "vgs") ?format "spice" ?maxLineWidth 1000)

file = outfile("./transistors.csv" "a")
fprintf(file "\n\nRegion 0 is cutoff.\nRegion 1 is linear.\nRegion 2 is saturation .\nRegion 3 is subthreshold.\nRegion 4 is breakdown.\n\nType 0 is nMOS. \nType 1 is pMOS.")
close(file)

For the IHP design kit use:

selectResult('dcOpInfo)
report(?output "./transistors.csv" ?param list("model" "gm" "gmb" "gds" "ids" "idsat" "vth" "region" "cgs" "cgd" "vds" "vsat" "vgs") ?format "spice" ?maxLineWidth 1000)

file = outfile("./transistors.csv" "a")
fprintf(file "\n\nRegion 0 is cutoff.\nRegion 1 is linear.\nRegion 2 is saturation .\nRegion 3 is subthreshold.\nRegion 4 is breakdown.\n\nType 0 is nMOS. \nType 1 is pMOS.")
close(file)

This script uses the results from the previous Debug Test (from ADE XL Test Editor). Before running the script, run a Debug Test with DC analysis:

Run debug simulation.png


After running DC analysis, run the script by entering the following into the Virtuoso Log Window (with file name and location as mentioned above): load("./transistors.ocn")

Run transistors script.png


After running the script, you can open the results file from the terminal using for example: gedit transistors.csv &


The results file can also be imported into LibreOffice Calc (similar to Microsoft Excel) using File->Open, then choose the .csv file and enter the settings as in the following image:

Csv import libreoffice.png