Browse Source

no pmf, DBL_MAX

pre-master-46
h_vogt 16 years ago
parent
commit
7c7ff52262
  1. 2
      ChangeLog
  2. 2
      src/spicelib/devices/mesa/mesa.c
  3. 6
      src/spicelib/devices/mesa/mesamparam.c
  4. 5
      src/spicelib/devices/mesa/mesasetup.c

2
ChangeLog

@ -1,6 +1,6 @@
============================ Rework-22 ==================================
2010-09-26 Holger Vogt
2010-10-02 Holger Vogt
* mesadefs.h, mesamsak.c, mesamparam.c, mesasetup.c
jfetmask.c: remove NAN or exp -312 outputs

2
src/spicelib/devices/mesa/mesa.c

@ -111,7 +111,7 @@ IFparm MESAmPTable[] = { /* model parameters */
IOP( "epsi", MESA_MOD_EPSI, IF_REAL,""),
IOP( "cas", MESA_MOD_CAS, IF_REAL,""),
IOP( "cbs", MESA_MOD_CBS, IF_REAL,""),
IP( "pmf", MESA_MOD_PMF, IF_FLAG,"P type MESfet model"),
IP( "pmf", MESA_MOD_PMF, IF_FLAG,"P type MESfet model"),
IP( "nmf", MESA_MOD_NMF, IF_FLAG,"N type MESfet model"),
OP( "gd", MESA_MOD_DRAINCONDUCT, IF_REAL,"Drain conductance"),
OP( "gs", MESA_MOD_SOURCECONDUCT, IF_REAL,"Source conductance"),

6
src/spicelib/devices/mesa/mesamparam.c

@ -169,6 +169,12 @@ MESAmParam(int param, IFvalue *value, GENmodel *inModel)
model->MESAtype = NMF;
}
break;
case MESA_MOD_PMF:
if(value->iValue) {
fprintf(stderr, "Only nmf model type supported, set to nmf\n");
model->MESAtype = NMF;
}
break;
case MESA_MOD_TVTO:
model->MESAtvtoGiven = TRUE;
model->MESAtvto = value->rValue;

5
src/spicelib/devices/mesa/mesasetup.c

@ -29,6 +29,7 @@ MESAsetup(SMPmatrix *matrix, GENmodel *inModel, CKTcircuit *ckt, int *states)
/* loop through all the diode models */
for( ; model != NULL; model = model->MESAnextModel ) {
if( (model->MESAtype != NMF) ) {
fprintf(stderr, "Only nmf model type supported, set to nmf\n");
model->MESAtype = NMF;
}
if(!model->MESAthresholdGiven) {
@ -215,12 +216,12 @@ MESAsetup(SMPmatrix *matrix, GENmodel *inModel, CKTcircuit *ckt, int *states)
if(model->MESAdrainResist != 0) {
model->MESAdrainConduct = 1./model->MESAdrainResist;
} else {
model->MESAdrainConduct = 0.;
model->MESAdrainConduct = DBL_MAX;
}
if(model->MESAsourceResist != 0) {
model->MESAsourceConduct = 1./model->MESAsourceResist;
} else {
model->MESAsourceConduct = 0.;
model->MESAsourceConduct = DBL_MAX;
}
model->MESAvcrit = 0.; /* until model has changed */

Loading…
Cancel
Save