Qucs-GUI  0.0.19
/home/travis/build/Qucs/qucs/qucs/qucs/components/photodiode.cpp
Go to the documentation of this file.
00001 /*
00002  * photodiode.cpp - device implementations for photodiode module
00003  *
00004  * This is free software; you can redistribute it and/or modify
00005  * it under the terms of the GNU General Public License as published by
00006  * the Free Software Foundation; either version 2, or (at your option)
00007  * any later version.
00008  * 
00009  */
00010 
00011 #include "photodiode.h"
00012 
00013 photodiode::photodiode()
00014 {
00015   Description = QObject::tr ("Photodiode verilog device");
00016 
00017   Props.append (new Property ("N", "1.35", false,
00018     QObject::tr ("photodiode emission coefficient")));
00019   Props.append (new Property ("Rseries", "1e-3", false,
00020     QObject::tr ("series lead resistance")
00021     +" ("+QObject::tr ("Ohm")+")"));
00022   Props.append (new Property ("Is", "0.34e-12", false,
00023     QObject::tr ("diode dark current")
00024     +" ("+QObject::tr ("A")+")"));
00025   Props.append (new Property ("Bv", "60", false,
00026     QObject::tr ("reverse breakdown voltage")
00027     +" ("+QObject::tr ("V")+")"));
00028   Props.append (new Property ("Ibv", "1e-3", false,
00029     QObject::tr ("current at reverse breakdown voltage")
00030     +" ("+QObject::tr ("A")+")"));
00031   Props.append (new Property ("Vj", "0.7", false,
00032     QObject::tr ("junction potential")
00033     +" ("+QObject::tr ("V")+")"));
00034   Props.append (new Property ("Cj0", "60e-12", false,
00035     QObject::tr ("zero-bias junction capacitance")
00036     +" ("+QObject::tr ("F")+")"));
00037   Props.append (new Property ("M", "0.5", false,
00038     QObject::tr ("grading coefficient")));
00039   Props.append (new Property ("Area", "1.0", false,
00040     QObject::tr ("diode relative area")));
00041   Props.append (new Property ("Tnom", "26.85", false,
00042     QObject::tr ("parameter measurement temperature")
00043     +" ("+QObject::tr ("Celsius")+")"));
00044   Props.append (new Property ("Fc", "0.5", false,
00045     QObject::tr ("forward-bias depletion capacitance coefficient")));
00046   Props.append (new Property ("Tt", "10e-9", false,
00047     QObject::tr ("transit time")
00048     +" ("+QObject::tr ("s")+")"));
00049   Props.append (new Property ("Xti", "3.0", false,
00050     QObject::tr ("saturation current temperature exponent")));
00051   Props.append (new Property ("Eg", "1.16", false,
00052     QObject::tr ("energy gap")
00053     +" ("+QObject::tr ("eV")+")"));
00054   Props.append (new Property ("Responsivity", "0.5", false,
00055     QObject::tr ("responsivity")
00056     +" ("+QObject::tr ("A/W")+")"));
00057   Props.append (new Property ("Rsh", "5e8", false,
00058     QObject::tr ("shunt resistance")
00059     +" ("+QObject::tr ("Ohm")+")"));
00060   Props.append (new Property ("QEpercent", "80", false,
00061     QObject::tr ("quantum efficiency")
00062     +" ("+QObject::tr ("%")+")"));
00063   Props.append (new Property ("Lambda", "900", false,
00064     QObject::tr ("light wavelength")
00065     +" ("+QObject::tr ("nm")+")"));
00066   Props.append (new Property ("LEVEL", "1", false,
00067     QObject::tr ("responsivity calculator selector")));
00068   Props.append (new Property ("Kf", "1e-12", false,
00069     QObject::tr ("flicker noise coefficient")));
00070   Props.append (new Property ("Af", "1.0", false,
00071     QObject::tr ("flicker noise exponent")));
00072   Props.append (new Property ("Ffe", "1.0", false,
00073     QObject::tr ("flicker noise frequency exponent")));
00074   Props.append (new Property ("Temp", "26.85", false,
00075     QObject::tr ("simulation temperature")));
00076 
00077   createSymbol ();
00078   tx = x2 + 4;
00079   ty = y1 + 4;
00080   Model = "photodiode";
00081   Name  = "PD";
00082 }
00083 
00084 Component * photodiode::newOne()
00085 {
00086   photodiode * p = new photodiode();
00087   p->Props.getFirst()->Value = Props.getFirst()->Value; 
00088   p->recreate(0); 
00089   return p;
00090 }
00091 
00092 Element * photodiode::info(QString& Name, char * &BitmapFile, bool getNewOne)
00093 {
00094   Name = QObject::tr("Photodiode");
00095   BitmapFile = (char *) "photodiode";
00096 
00097   if(getNewOne) return new photodiode();
00098   return 0;
00099 }
00100 
00101 void photodiode::createSymbol()
00102 {
00103   Arcs.append(new Arc(-12,-12, 24, 24, 0, 16*360,QPen(Qt::red,2)));
00104   Lines.append(new Line(-30,  0, 30,  0,QPen(Qt::darkBlue,2)));
00105   Lines.append(new Line( -6, -9, -6,  9,QPen(Qt::darkBlue,2)));
00106   Lines.append(new Line(  6, -9,  6,  9,QPen(Qt::darkBlue,2)));
00107   Lines.append(new Line( -6,  0,  6, -9,QPen(Qt::darkBlue,2)));
00108   Lines.append(new Line( -6,  0,  6,  9,QPen(Qt::darkBlue,2)));
00109   Lines.append(new Line(  0, 12,  0,  30,QPen(Qt::green,2)));
00110 
00111   Ports.append(new Port( 30, 0));
00112   Ports.append(new Port(-30, 0));
00113   Ports.append(new Port( 0, 30));
00114 
00115   x1 = -30; y1 = -20;
00116   x2 =  30; y2 =  30;
00117 }
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines