⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 bsim1def.h

📁 spice中支持多层次元件模型仿真的可单独运行的插件源码
💻 H
📖 第 1 页 / 共 2 页
字号:
/**********Copyright 1990 Regents of the University of California.  All rights reserved.Author: 1985      Hong June Park, Thomas L. Quarles**********/#ifndef BSIM1#define BSIM1#include "ifsim.h"#include "gendefs.h"#include "cktdefs.h"#include "complex.h"    /* declarations for B1 MOSFETs */#define B1numStates 35           #define B1NDCOEFFS	82/* information needed for each instance */typedef struct sBSIM1instance {    struct sBSIM1model *B1modPtr;      /* pointer to model */    struct sBSIM1instance *B1nextInstance;  /* pointer to next instance of                                               *current model*/    IFuid B1name; /* pointer to character string naming this instance */    int B1owner;  /* number of owner process */    int B1states;     /* index into state table for this device */    int B1dNode;  /* number of the gate node of the mosfet */    int B1gNode;  /* number of the gate node of the mosfet */    int B1sNode;  /* number of the source node of the mosfet */    int B1bNode;  /* number of the bulk node of the mosfet */    int B1dNodePrime; /* number of the internal drain node of the mosfet */    int B1sNodePrime; /* number of the internal source node of the mosfet */    double B1l;   /* the length of the channel region */    double B1w;   /* the width of the channel region */    double B1drainArea;   /* the area of the drain diffusion */    double B1sourceArea;  /* the area of the source diffusion */    double B1drainSquares;    /* the length of the drain in squares */    double B1sourceSquares;   /* the length of the source in squares */    double B1drainPerimeter;    double B1sourcePerimeter;    double B1sourceConductance;   /*conductance of source(or 0):set in setup*/    double B1drainConductance;    /*conductance of drain(or 0):set in setup*/    double B1icVBS;   /* initial condition B-S voltage */    double B1icVDS;   /* initial condition D-S voltage */    double B1icVGS;   /* initial condition G-S voltage */    double B1von;    double B1vdsat;    int B1off;        /* non-zero to indicate device is off for dc analysis*/    int B1mode;       /* device mode : 1 = normal, -1 = inverse */    double B1vfb;      /* flat band voltage at given L and W */    double B1phi;      /* surface potential at strong inversion */    double B1K1;       /* bulk effect coefficient 1             */    double B1K2;       /* bulk effect coefficient 2             */    double B1eta;      /* drain induced barrier lowering        */    double B1etaB;     /* Vbs dependence of Eta                 */    double B1etaD;     /* Vds dependence of Eta                 */    double B1betaZero; /* Beta at vds = 0 and vgs = Vth         */    double B1betaZeroB; /* Vbs dependence of BetaZero           */    double B1betaVdd;  /* Beta at vds=Vdd and vgs=Vth           */    double B1betaVddB; /* Vbs dependence of BVdd             */    double B1betaVddD; /* Vds dependence of BVdd             */    double B1ugs;      /* Mobility degradation due to gate field*/    double B1ugsB;     /* Vbs dependence of Ugs                 */    double B1uds;      /* Drift Velocity Saturation due to Vds  */    double B1udsB;     /* Vbs dependence of Uds                 */    double B1udsD;     /* Vds dependence of Uds                 */    double B1subthSlope; /* slope of subthreshold current with Vgs*/    double B1subthSlopeB; /* Vbs dependence of Subthreshold Slope */    double B1subthSlopeD; /* Vds dependence of Subthreshold Slope */    double B1GDoverlapCap;/* Gate Drain Overlap Capacitance       */    double B1GSoverlapCap;/* Gate Source Overlap Capacitance      */    double B1GBoverlapCap;/* Gate Bulk Overlap Capacitance        */    double B1vt0;    double B1vdd;         /* Supply Voltage                       */    double B1temp;    double B1oxideThickness;    unsigned B1channelChargePartitionFlag :1;    unsigned B1lGiven :1;    unsigned B1wGiven :1;    unsigned B1drainAreaGiven :1;    unsigned B1sourceAreaGiven    :1;    unsigned B1drainSquaresGiven  :1;    unsigned B1sourceSquaresGiven :1;    unsigned B1drainPerimeterGiven    :1;    unsigned B1sourcePerimeterGiven   :1;    unsigned B1dNodePrimeSet  :1;    unsigned B1sNodePrimeSet  :1;    unsigned B1icVBSGiven :1;    unsigned B1icVDSGiven :1;    unsigned B1icVGSGiven :1;    unsigned B1vonGiven   :1;    unsigned B1vdsatGiven :1;    double *B1DdPtr;      /* pointer to sparse matrix element at                                     * (Drain node,drain node) */    double *B1GgPtr;      /* pointer to sparse matrix element at                                     * (gate node,gate node) */    double *B1SsPtr;      /* pointer to sparse matrix element at                                     * (source node,source node) */    double *B1BbPtr;      /* pointer to sparse matrix element at                                     * (bulk node,bulk node) */    double *B1DPdpPtr;    /* pointer to sparse matrix element at                                     * (drain prime node,drain prime node) */    double *B1SPspPtr;    /* pointer to sparse matrix element at                                     * (source prime node,source prime node) */    double *B1DdpPtr;     /* pointer to sparse matrix element at                                     * (drain node,drain prime node) */    double *B1GbPtr;      /* pointer to sparse matrix element at                                     * (gate node,bulk node) */    double *B1GdpPtr;     /* pointer to sparse matrix element at                                     * (gate node,drain prime node) */    double *B1GspPtr;     /* pointer to sparse matrix element at                                     * (gate node,source prime node) */    double *B1SspPtr;     /* pointer to sparse matrix element at                                     * (source node,source prime node) */    double *B1BdpPtr;     /* pointer to sparse matrix element at                                     * (bulk node,drain prime node) */    double *B1BspPtr;     /* pointer to sparse matrix element at                                     * (bulk node,source prime node) */    double *B1DPspPtr;    /* pointer to sparse matrix element at                                     * (drain prime node,source prime node) */    double *B1DPdPtr;     /* pointer to sparse matrix element at                                     * (drain prime node,drain node) */    double *B1BgPtr;      /* pointer to sparse matrix element at                                     * (bulk node,gate node) */    double *B1DPgPtr;     /* pointer to sparse matrix element at                                     * (drain prime node,gate node) */    double *B1SPgPtr;     /* pointer to sparse matrix element at                                     * (source prime node,gate node) */    double *B1SPsPtr;     /* pointer to sparse matrix element at                                     * (source prime node,source node) */    double *B1DPbPtr;     /* pointer to sparse matrix element at                                     * (drain prime node,bulk node) */    double *B1SPbPtr;     /* pointer to sparse matrix element at                                     * (source prime node,bulk node) */    double *B1SPdpPtr;    /* pointer to sparse matrix element at                                     * (source prime node,drain prime node) */#ifndef NODISTO	double B1dCoeffs[B1NDCOEFFS];#else /* NODISTO */	double *B1dCoeffs;#endif /* NODISTO */} B1instance ;#ifndef CONFIG#define B1vbd B1states+ 0#define B1vbs B1states+ 1#define B1vgs B1states+ 2#define B1vds B1states+ 3#define B1cd B1states+ 4#define B1id B1states+ 4#define B1cbs B1states+ 5#define B1ibs B1states+ 5#define B1cbd B1states+ 6#define B1ibd B1states+ 6#define B1gm B1states+ 7#define B1gds B1states+ 8#define B1gmbs B1states+ 9#define B1gbd B1states+ 10#define B1gbs B1states+ 11#define B1qb B1states+ 12#define B1cqb B1states+ 13#define B1iqb B1states+ 13#define B1qg B1states+ 14#define B1cqg B1states+ 15#define B1iqg B1states+ 15#define B1qd B1states+ 16#define B1cqd B1states+ 17#define B1iqd B1states+ 17#define B1cggb B1states+ 18#define B1cgdb B1states+ 19#define B1cgsb B1states+ 20#define B1cbgb B1states+ 21#define B1cbdb B1states+ 22#define B1cbsb B1states+ 23#define B1capbd B1states+ 24#define B1iqbd B1states+ 25#define B1cqbd B1states+ 25#define B1capbs B1states+ 26#define B1iqbs B1states+ 27#define B1cqbs B1states+ 27#define B1cdgb B1states+ 28#define B1cddb B1states+ 29#define B1cdsb B1states+ 30#define B1vono B1states+ 31#define B1vdsato B1states+ 32#define B1qbs  B1states+ 33#define B1qbd  B1states+ 34/* * the following naming convention is used: * x = vgs * y = vbs * z = vds * DrC is the DrCur * therefore qg_xyz stands for the coefficient of the vgs*vbs*vds * term in the multidimensional Taylor expansion for qg; and DrC_x2y * for the coeff. of the vgs*vgs*vbs term in the DrC expansion. */#define	qg_x		B1dCoeffs[0]#define	qg_y		B1dCoeffs[1]#define	qg_z		B1dCoeffs[2]#define	qg_x2		B1dCoeffs[3]#define	qg_y2		B1dCoeffs[4]#define	qg_z2		B1dCoeffs[5]#define	qg_xy		B1dCoeffs[6]#define	qg_yz		B1dCoeffs[7]#define	qg_xz		B1dCoeffs[8]#define	qg_x3		B1dCoeffs[9]#define	qg_y3		B1dCoeffs[10]#define	qg_z3		B1dCoeffs[11]#define	qg_x2z		B1dCoeffs[12]#define	qg_x2y		B1dCoeffs[13]#define	qg_y2z		B1dCoeffs[14]#define	qg_xy2		B1dCoeffs[15]#define	qg_xz2		B1dCoeffs[16]#define	qg_yz2		B1dCoeffs[17]#define	qg_xyz		B1dCoeffs[18]#define	qb_x		B1dCoeffs[19]#define	qb_y		B1dCoeffs[20]#define	qb_z		B1dCoeffs[21]#define	qb_x2		B1dCoeffs[22]#define	qb_y2		B1dCoeffs[23]#define	qb_z2		B1dCoeffs[24]#define	qb_xy		B1dCoeffs[25]#define	qb_yz		B1dCoeffs[26]#define	qb_xz		B1dCoeffs[27]#define	qb_x3		B1dCoeffs[28]#define	qb_y3		B1dCoeffs[29]#define	qb_z3		B1dCoeffs[30]#define	qb_x2z		B1dCoeffs[31]#define	qb_x2y		B1dCoeffs[32]#define	qb_y2z		B1dCoeffs[33]#define	qb_xy2		B1dCoeffs[34]#define	qb_xz2		B1dCoeffs[35]#define	qb_yz2		B1dCoeffs[36]#define	qb_xyz		B1dCoeffs[37]#define	qd_x		B1dCoeffs[38]#define	qd_y		B1dCoeffs[39]#define	qd_z		B1dCoeffs[40]#define	qd_x2		B1dCoeffs[41]#define	qd_y2		B1dCoeffs[42]#define	qd_z2		B1dCoeffs[43]#define	qd_xy		B1dCoeffs[44]#define	qd_yz		B1dCoeffs[45]#define	qd_xz		B1dCoeffs[46]#define	qd_x3		B1dCoeffs[47]#define	qd_y3		B1dCoeffs[48]#define	qd_z3		B1dCoeffs[49]#define	qd_x2z		B1dCoeffs[50]#define	qd_x2y		B1dCoeffs[51]#define	qd_y2z		B1dCoeffs[52]#define	qd_xy2		B1dCoeffs[53]#define	qd_xz2		B1dCoeffs[54]#define	qd_yz2		B1dCoeffs[55]#define	qd_xyz		B1dCoeffs[56]#define	DrC_x		B1dCoeffs[57]#define	DrC_y		B1dCoeffs[58]#define	DrC_z		B1dCoeffs[59]#define	DrC_x2		B1dCoeffs[60]#define	DrC_y2		B1dCoeffs[61]#define	DrC_z2		B1dCoeffs[62]#define	DrC_xy		B1dCoeffs[63]#define	DrC_yz		B1dCoeffs[64]#define	DrC_xz		B1dCoeffs[65]#define	DrC_x3		B1dCoeffs[66]#define	DrC_y3		B1dCoeffs[67]#define	DrC_z3		B1dCoeffs[68]#define	DrC_x2z		B1dCoeffs[69]#define	DrC_x2y		B1dCoeffs[70]#define	DrC_y2z		B1dCoeffs[71]#define	DrC_xy2		B1dCoeffs[72]#define	DrC_xz2		B1dCoeffs[73]#define	DrC_yz2		B1dCoeffs[74]#define	DrC_xyz		B1dCoeffs[75]#define	gbs1		B1dCoeffs[76]#define	gbs2		B1dCoeffs[77]#define	gbs3		B1dCoeffs[78]#define	gbd1		B1dCoeffs[79]#define	gbd2		B1dCoeffs[80]#define	gbd3		B1dCoeffs[81]#endif/* per model data */typedef struct sBSIM1model {       /* model structure for a resistor */    int B1modType;    /* type index of this device type */    struct sBSIM1model *B1nextModel;    /* pointer to next possible model                                           *in linked list */    B1instance * B1instances; /* pointer to list of instances                                    * that have this model */    IFuid B1modName;       /* pointer to character string naming this model */    int B1type;       /* device type : 1 = nmos,  -1 = pmos */    double B1vfb0;    double B1vfbL;    double B1vfbW;    double B1phi0;    double B1phiL;    double B1phiW;    double B1K10;    double B1K1L;

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -